Ask Your Question

Revision history [back]

[c++] VideoCapture always returns a null image

Dear folks, I always used VideoCapture to take frames from web cams but since I've used an industrial camera (the david laser scanner one), VideoCapture objects always returns a null image. I've already known I have to change the ID numbers in the VideoCapture constructor but the problem still remains.

Does anyone know the reason why this problem happens?

I tried this new camera using skype and it works perfectly so it should not be neither an HW problem nor an OS driver one.

Thank you

[c++] VideoCapture always returns a null image

Dear folks, I always used VideoCapture to take frames from web cams but since I've used an industrial camera (the david laser scanner one), VideoCapture objects always returns a null image. I've already known I have to change the ID numbers in the VideoCapture constructor but the problem still remains.

VideoCapture cap(0);

cap>>image; // this function return a null image

If I use grap and retrieve
bool t = cap.grab(); //returns true t = cap.retrieve(image); //returns false

Does anyone know the reason why this problem happens?

I tried this new camera using skype and it works perfectly so it should not be neither an HW problem nor an OS driver one.

Thank you

[c++] VideoCapture always returns a null image

Dear folks, I always used VideoCapture to take frames from web cams but since I've used an industrial camera (the david laser scanner one), VideoCapture objects always returns a null image. I've already known I have to change the ID numbers in the VideoCapture constructor but the problem still remains.

VideoCapture cap(0);

cap>>image; // this function return a null image

If I use grap and retrieve

bool t = cap.grab(); //returns true true

t = cap.retrieve(image); //returns false

Does anyone know the reason why this problem happens?

I tried this new camera using skype and it works perfectly so it should not be neither an HW problem nor an OS driver one.

Thank you