Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

CameraWrapperConnector cannot dlopen camera wrapper library

There are numerous questions here, but none of them quite match my case. (And a lot are unanswered anyway.)

I'm using OpenCV for Android 2.6.4.1 (the prebuilt version downloadable from the main site) to build a native App for Android (4.1.2) on a Samsung Galaxy Note 2 with Qt 5.0.1 for Android (using QtCreator 2.7.2) on a x86_64 Linux host.

I've linked against the libraries in the ../sdk/native/libs/armeabi-v7a folder. (I haven't built OpenCV from source, I'm just using what was in the downloaded package). This includes a libopencv_androidcam.a library. I've also downloaded the market app "OpenCV Manager".

The sample .apks from the samples directory work on my phone, but I haven't tried to build them on my own, as I don't have a Java development environment set up.

Starting my application, which contains a cv::VideoCapture inputCapture(CV_CAM_ANDROID); statement, I get the following error and no camera input:

E/OpenCV::camera(15299): CameraWrapperConnector::connectToLib ERROR: cannot dlopen camera wrapper library
E/OpenCV::camera(15299): Native_camera returned opening error: 4

My questions:

  • Should this work? I have seen a lot of bug reports, but all with older OpenCV versions and newer/older Android versions. Bonus points if it has been seen working on this phone model.
  • Should this work out of the box with the downloaded OpenCV Android SDK? Or do I need to build OpenCV from source with some special options? (Which ones?)
  • Do I need special library versions on the phone itself? Do I need to have root access to the device to make this work?
  • Are there any "known to be working" Andoid examples using native code instead of Java?

Thanks a lot for any help!

CameraWrapperConnector cannot dlopen Cannot use camera wrapper libraryon Android 4.1.2 with OpenCV 2.4.6

There are numerous questions here, but none of them quite match my case. (And a lot are unanswered anyway.)

I'm using OpenCV for Android 2.6.4.1 2.4.6 (the prebuilt version downloadable from the main site) to build a native App for Android (4.1.2) on a Samsung Galaxy Note 2 with Qt 5.0.1 for Android (using QtCreator 2.7.2) on a x86_64 Linux host.

I've linked against the libraries in the ../sdk/native/libs/armeabi-v7a folder. (I haven't built OpenCV from source, I'm just using what was in the downloaded package). This includes a libopencv_androidcam.a library. I've also downloaded the market app "OpenCV Manager".

The sample .apks from the samples directory work on my phone, but I haven't tried to build them on my own, as I don't have a Java development environment set up.

Starting my application, which contains a cv::VideoCapture inputCapture(CV_CAM_ANDROID); statement, I get the following error and no camera input:

E/OpenCV::camera(15299): CameraWrapperConnector::connectToLib ERROR: cannot dlopen camera wrapper library
E/OpenCV::camera(15299): Native_camera returned opening error: 4

My questions:

  • Should this work? I have seen a lot of bug reports, but all with older OpenCV versions and newer/older Android versions. Bonus points if it has been seen working on this phone model.
  • Should this work out of the box with the downloaded OpenCV Android SDK? Or do I need to build OpenCV from source with some special options? (Which ones?)
  • Do I need special library versions on the phone itself? Do I need to have root access to the device to make this work?
  • Are there any "known to be working" Andoid examples using native code instead of Java?

Thanks a lot for any help!