can't open android camera with opencv.

asked 2013-05-29 01:26:51 -0500

okgogo2000 gravatar image

I'm using opencv 2.4.5 trying to open the android camera with NDK.

I'm tring to use cv::VideoCapture videoCapture(CV_CAP_ANDROID + 0);

or

CvCapture *capture = cvCaptureFromCAM(CV_CAP_ANDROID + 0);

to open the camera. it always can't open the camera success.

The log in Eclipse always show the two errors:

OpenCV::camera: CameraWrapperConnector::connectToLib ERROR: cannot dlopen camera wrapper library OpenCV::camera: Native_camera returned opening error: 4

I'm testing with the SAMSUNG GT-PG3100 with Android 4.1.2

and another no brand device with Android 4.1.1

I tried 1 day already and still can't slove the problem. anyone can help me?

edit retag flag offensive close merge delete

Comments

Did your opencv build include the android camera stuff? I think it doesn't come out of the box with that enabled. Good luck with Samsung and their cameras in any case. I've spent weeks getting their dorked-with-android phones to do what other do in minutes. :-((

Howard gravatar imageHoward ( 2013-05-29 16:22:52 -0500 )edit