VideoGrabber hanging in mingw32

#1

I am developing an app that reads multiple external cameras. I am using windows 10 64 bits. I am using mingw32 for compiling. I am using the latest GitHub openframeworks code.

ofLog(OF_LOG_NOTICE) << "Starting to open Cam: " << mCamId<<std::endl;
mCam.close();

mCam.setDeviceID(mCamId);
mCam.setDesiredFrameRate(mFps);
mCam.setUseTexture(true);

ofLog(OF_LOG_NOTICE) << "Cam:"<<std::endl;

bool camSetup = mCam.initGrabber(mDim.x, mDim.y);

Here is the output. When I run the following code in mingw32, the program hangs. Sometimes the videograbber can detect the camera and work correctly without a problem, but this is at least at the fifth try. The problem is when I am running multiple cameras that the videograbber hangs in cam 0 or 1, or 2.

[notice ] Starting to open Cam: 1
[notice ] Cam:

***** VIDEOINPUT LIBRARY - 0.2000 - TFW2013 *****

[notice ] ofDirectShowGrabber: initGrabber(): choosing 1

Has anyone encountered this problem before?

Thank you for the help
Thomas