Opencv Java exception-Collection of common programming errors
Hello I’m getting next exception when trying to run java project that uses opencv libraries:
Exception in thread "main" java.lang.UnsatisfiedLinkError: no opencv_java in java.library.path
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.loadLibrary0(Unknown Source)
at java.lang.System.loadLibrary(Unknown Source)
at org.opencv.highgui.Highgui.(Highgui.java:416)
at teste.main(teste.java:21)
Can it be caused of wrong installation of opencv? Or maybe some import is missing? I’m trying to follow instructions from here. Also I’m using Windows 7 and I want to create a simple Java project in Eclipse(not Android)
- So I’ve extracted javacv from OpenCV-2.4.2.exe file to C:\
- Then executed “cmake -G “MinGW Makefiles” -DBUILD_opencv_java=ON C:\opencv” command and after that, “mingw32-make”. Everything was build without errors or warnings
- After I’ve added opencv dll’s to my Environment Variables
Thanks for your attention
Originally posted 2013-11-06 03:16:16.