Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import cv2
- import sys
- import numpy as np
- import serial
- import struct
- import time
- if __name__ == '__main__' :
- # Read video
- video = cv2.VideoCapture(0)
- #ok, frame = video.read()
- while(True):
- # Read a new frame
- ok, frame = video.read()
- if not ok:
- break
- # Display result'
- cv2.imshow("Tracking", frame)
- # Exit if ESC pressed
- if cv2.waitKey(1) & 0xFF == ord('q'):
- break
- video.release()
- cv2.destroyAllWindows()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement