64ビット、JDK 1.7、OpenCV 2.40、コード用JavaCVの新バージョン
package test;
import static com.googlecode.javacv.cpp.opencv_core;
import static com.googlecode.javacv.cpp.opencv_highgui;
import com.googlecode.javacv.CanvasFrame;
public class Test{
public static void main(String args) {
final IplImage image = cvLoadImage("img1.png");
final CanvasFrame canvas = new CanvasFrame("Demo");
canvas.showImage(image);
canvas.setDefaultCloseOperation(javax.swing.JFrame.EXIT_ON_CLOSE);
}
}
上記のコードに対して次のエラーが発生します。
Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\Users\BBPATIL\AppData\Local\Temp\javacpp173171889406337\jniopencv_core.dll: Can't find dependent libraries
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1928)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1825)
at java.lang.Runtime.load0(Runtime.java:792)
at java.lang.System.load(System.java:1059)
at com.googlecode.javacpp.Loader.loadLibrary(Loader.java:418)
at com.googlecode.javacpp.Loader.load(Loader.java:368)
at com.googlecode.javacpp.Loader.load(Loader.java:315)
at com.googlecode.javacv.cpp.opencv_core.<clinit>(opencv_core.java:131)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at com.googlecode.javacpp.Loader.load(Loader.java:334)
at com.googlecode.javacv.cpp.opencv_imgproc.<clinit>(opencv_imgproc.java:96)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at com.googlecode.javacpp.Loader.load(Loader.java:334)
at com.googlecode.javacv.cpp.opencv_highgui.<clinit>(opencv_highgui.java:91)
at sdmcetd.main(sdmcetd.java:11)
Java Result: 1
誰か早く助けてください..!!!!