Ask Your Question

Potass's profile - activity

2015-10-28 11:31:00 -0600 received badge  Nice Question (source)
2015-10-28 11:30:57 -0600 received badge  Teacher (source)
2015-10-16 03:51:54 -0600 received badge  Self-Learner (source)
2015-10-16 03:51:54 -0600 received badge  Necromancer (source)
2015-10-15 08:04:56 -0600 answered a question OpenCV 3.0 for Android - static initialization not loading new modules

Seems working now using the updated version from 23.6.2015.

2015-06-21 08:05:18 -0600 received badge  Enthusiast
2015-06-15 10:14:16 -0600 received badge  Student (source)
2015-06-14 13:38:33 -0600 asked a question OpenCV 3.0 for Android - static initialization not loading new modules

I recently moved my Android project from OpenCV 2.4.10 to OpenCV 3.0.

I statically initialize OpenCV using this code:

OpenCVLoader.initDebug();

When I run my app, I get this exception:

java.lang.UnsatisfiedLinkError: Native method not found: org.opencv.imgcodecs.Imgcodecs.imread_1:(Ljava/lang/String;)J

Imgcodecs is a new module in OpenCV 3.0 which replaces Highgui from OpenCV 2.4.* if I am right.

I can see following output in logs from OpenCV when it initializes:

Version control:               2.4.10
...
To be built:                 core androidcamera flann imgproc highgui features2d calib3d ml objdetect video contrib photo java legacy ocl stitching superres ts videostab

From the information above I guess that the OpenCVLoader of OpenCV 3.0 initializes only the old modules from 2.4.10. You can see that it loads highgui module which should not be needed anymore.

Is this a bug of new OpenCV or am I missing something? Is there some workaround how to load also the new modules? Thanks.