Ask Your Question
0

Why is am I getting this message when attempting to access video feed from a webcam?

asked 2019-10-25 15:08:39 -0600

vjv gravatar image

error program

I am trying to run a fairly basic program that simply opens up the video feed from a USB connected webcam instead of my computer webcam. I get this error and I do not know how to fix it. I have checked that the webcam is being picked up by linux by using lsusb and opening the webcam feed in cheese. How do I fix this issue?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-10-26 21:25:01 -0600

supra56 gravatar image

Change this:

cap = cv2.VideoCapture(1)

to:

cap = cv2.VideoCapture(0)
edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2019-10-25 15:08:39 -0600

Seen: 1,406 times

Last updated: Oct 26 '19