Use 2 cameras simultaneously
Hello I try use 2 webcams in opencv 3.10 simultaneously
It seems that framerate drops down from 25 fps to ~ 20 fps on one webcam and from 30 to ~20 fps on the other. If I comment all code relevant to one of the webcams fps comes back to 25 fps or 30 fps depending on webcam.
I tried different methods
VideoCapture >> UMat; //or
VideoCapture.grab(); VideoCapture.retrive();
Also I tried to grab fames in different threads using std::async
.
The result is always the same.
The code is simple loop with waitKey(30) and imshow
Platform: Windows 10 x64 Visual Studio 2015 community,
Build type is win32
it's probably more a usb bandwidth problem.
a single usb2 controller can barely handle the output of a single webcam, so if you want to use more cams, either reduce the resolution, or try to plug one in the front, the other into the back of your box (so they end up on different controllers)
take a look at this
berak, No, it's not about usb bandwidth. When I use iSpy framerate is correct for both.