3
votes

I have two graph in my program each one can control a USB camera to capture video data.

I can start them separately without problem like:

cam_a.start();
sleep(100);
cam_b.start();

However,without the "sleep" the second graph will not execute correctly,like no file writing and no frame display.

Anyone can help to solve this problem?

Win7 64 bits, windows sdk 7 Logitech c210 webcam Logitech c510 webcam Directshow video capture.

1
Maybe dshow's bug or bug within one of the CAM driver? Can you test your app again with another two different CAMs? - Xiè Jìléi
Or, fake CAM by two file source? - Xiè Jìléi
I can make it work with one DV cam(1394)+usb webcam, or two Dv cams(1394). But if two usb webcams then I must put a delay there. - Steven Du
Is c210 usb cam? What if two usb cams of other model? I guess the problem maybe the c210 device driver not thread safe. - Xiè Jìléi

1 Answers

2
votes

In Windows Logitech USB Cams were usually TWAIN/WIA based (http://www.twain.org, http://msdn.microsoft.com/en-us/library/ms630368%28v=vs.85%29.aspx). Your issue is probably caused by the Logitech TWAIN/WIA driver not being thread safe or having a bug. Your DV-1394 Cam probably uses a diferent driver so there is no colision with the Logitech driver.