Use Android OpenCV wrapper from java Console application in Eclipse

139 views
Skip to first unread message

diegovarese

unread,
May 19, 2012, 8:46:52 PM5/19/12
to android...@googlegroups.com
I'm trying to use the Android OpenCV wrapper from a Console app. To do that I created the Eclipse project and added a project reference to the OpenCV-2.4.0 project. However, when I run it I get the following Exception:

Exception in thread "main" java.lang.UnsatisfiedLinkError: no opencv_java in java.library.path

I saw the following thread about this error:

https://groups.google.com/forum/?fromgroups#!topic/android-opencv/NpnKPVdwzJ4

but this applies only if you have the Android section in the project properties, which I do not have. How can I specify to the console application where the native libraries are? I'm assuming I need to somehow link to /OpenCV-2.4.0-android-bin/OpenCV-2.4.0/libs/x86 right?

Thanks

Diego

Andrey Pavlenko

unread,
May 21, 2012, 10:40:22 AM5/21/12
to android...@googlegroups.com
Please specify the target platform that you'd like to run your app on.

Diego Varese

unread,
May 21, 2012, 12:36:10 PM5/21/12
to android...@googlegroups.com
I'm running it on OS X Lion.

RyanfaeScotland

unread,
Jun 14, 2012, 11:16:05 AM6/14/12
to android...@googlegroups.com
Try using the following on the command line.

java -jar YourProgram.jar -Djava.library.path /OpenCV-2.4.0-android-bin/OpenCV-2.4.0/libs/x86 (or wherever the opencv_java.so file is)

Andrey Pavlenko

unread,
Jun 18, 2012, 8:57:18 AM6/18/12
to android...@googlegroups.com
Currently we support Java API on Android only.
Reply all
Reply to author
Forward
0 new messages