Skip to content

Commit

Permalink
use opencv generic VideoCapture only
Browse files Browse the repository at this point in the history
so that it works with video file or camera easily
  • Loading branch information
tobybreckon committed Nov 9, 2023
1 parent 15867b4 commit e26ec1a
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions capture_video.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,7 @@

# define video capture object

try:
# to use a non-buffered camera stream (via a separate thread)

import camera_stream
cap = camera_stream.CameraVideoStream(use_tapi=False)

except BaseException:
# if not then just use OpenCV default

print("INFO: camera_stream class not found - camera input may be buffered")
cap = cv2.VideoCapture()
cap = cv2.VideoCapture()

# define display window name

Expand Down

0 comments on commit e26ec1a

Please sign in to comment.