I am trying to capture from 2 web camera simultaneously using directshow. IF I capture one by one OR one at a time both are working properly. But not able to capture simultaneously from same application.
I tried to use various applications available from net like dorgem, virtualdub. These applications are also able to show only one camera at a time when another camera is opened in second application it gives "a device attached is not functioning" but individually but only one camera is able to displays properly. Sample windows SDK applications are also behaving similarly.
Drivers look like installed properly as they are working individually properly. I also tried to graphedit but no success.
As Roman Said, trying another brand or model of webcam might help. There is a large variation in how well various cameras perform. What model of webcam are you using?
I would guess that if you are using two of the exact same camera the device driver doesn't correctly handle the two cameras, in that it is not smart enough to distinguish the two. You might have some success by renaming one of the cameras maybe through the device manager or in the registry, but that is an ugly hack. Change one of the cameras to something different...
For USB Bandwidth issue, assuming USB 2.0, attempting to capture two 640x480 streams at 30fps pushes the limits of USB (that requires 52MB/s, compared to USB 2's THEORETICAL max of 60MB/s.)