OpenCV Python: cv2.VideoCapture can only find 2 of 3 cameras, Windows Camera app finds all

前端 未结 4 802
自闭症患者
自闭症患者 2021-02-19 00:38

I\'m trying to create 3 real-time capture frames with webcams into a USB hub into my laptop. Using the \"camera\" app on Windows, I can change the camera source one at a time an

4条回答
  •  温柔的废话
    2021-02-19 00:46

    First,we have to test your webcam can or cannot be connect to OPENCV.

    connect only one webcam,and run your program with cv2.VideoCapture(0).Parameter 0 mean there is a single camera connected. if all your webcam is ok,then it will be problem of index,there is some code which will find the deviceID assigned to the cam.

    and if some webcam unfortunately fail,then it will be hard.

    In this case you have to create your own function that grabs using the SDK and write the image into a cv::Mat.

提交回复
热议问题