[Python] How to identify specific camera in OpenCV on Windows?

Discussão em 'Python' iniciado por Stack, Janeiro 15, 2025.

  1. Stack

    Stack Membro Participativo

    I am using two identical cameras, in Windows, with Open CV in Python. I need to be able to detect which camera is which, so I know where my video is coming from. The cv2.VideoCapture() function only lets me specify an index, and those indices can change on reboot.

    Is there a way to consistently discover which camera is at which index every time I run my application?

    The best idea I have so far is to put a QR code in the frame, but it seems like I should be able to correlate cameras to indices directly somehow.

    Continue reading...

Compartilhe esta Página