Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

please help me in configure the opencv for eclipse juno in java

i write a test program for opencv in java and i face with this exception my code is: package ImageProc;

import org.opencv.core.Mat; import org.opencv.highgui.Highgui; import org.opencv.highgui.VideoCapture;

public class Test { public static void main(String[] args) { System.out.println("hello opencv"); System.loadLibrary("opencv-245"); VideoCapture capture = new VideoCapture(0); if(!capture.isOpened()) System.out.println("Did not connect to camera!"); else System.out.println("Found WebCam :"+capture.toString()); Mat mat = new Mat(); capture.retrieve(mat); Highgui.imwrite("me1.jpg", mat); capture.release();

}

}

in exception is: Exception in thread "main" java.lang.UnsatisfiedLinkError: no opencv-245 in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at ImageProc.Test.main(Test.java:14)

for configure,i do this work: 1-extract the opencv file in location c: 2-open eclipse and create a project 3-and then open the properties and go to java build path 4-click on the add library button ,then select user library ,click user library ,click new and create a new library with this name opencv.245 5-add opencv-245 jar file with click on add external jar file button 6-and for native library location :edit this and set this directory for this: c:/opencv/build/java/x64 7-and then click finsih

i run this code and appear this exception please help me

click to hide/show revision 2
No.2 Revision

please help me in configure the opencv for eclipse juno in java

i write a test program for opencv in java and i face with this exception my code is: package ImageProc;

import org.opencv.core.Mat; import org.opencv.highgui.Highgui; import org.opencv.highgui.VideoCapture;

public class Test { public static void main(String[] args) { System.out.println("hello opencv"); System.loadLibrary("opencv-245"); VideoCapture capture = new VideoCapture(0); if(!capture.isOpened()) System.out.println("Did not connect to camera!"); else System.out.println("Found WebCam :"+capture.toString()); Mat mat = new Mat(); capture.retrieve(mat); Highgui.imwrite("me1.jpg", mat); capture.release();

}

}

in exception is: Exception in thread "main" java.lang.UnsatisfiedLinkError: no opencv-245 in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at ImageProc.Test.main(Test.java:14)

for configure,i do this work: 1-extract the opencv file in location c: 2-open eclipse and create a project 3-and then open the properties and go to java build path 4-click on the add library button ,then select user library ,click user library ,click new and create a new library with this name opencv.245 5-add opencv-245 jar file with click on add external jar file button 6-and for native library location :edit this and set this directory for this: c:/opencv/build/java/x64 7-and then click finsih

i run this code and appear this exception please help me

click to hide/show revision 3
formatting

please help me in configure the opencv for eclipse juno in java

i write a test program for opencv in java and i face with this exception my code is: is:

package ImageProc;

ImageProc; import org.opencv.core.Mat; import org.opencv.highgui.Highgui; import org.opencv.highgui.VideoCapture;

org.opencv.highgui.VideoCapture; public class Test { public static void main(String[] args) { System.out.println("hello opencv"); System.loadLibrary("opencv-245"); VideoCapture capture = new VideoCapture(0); if(!capture.isOpened()) System.out.println("Did not connect to camera!"); else System.out.println("Found WebCam :"+capture.toString()); Mat mat = new Mat(); capture.retrieve(mat); Highgui.imwrite("me1.jpg", mat); capture.release();capture.release(); } }

in exception is:

}

}

in exception is: Exception in thread "main" java.lang.UnsatisfiedLinkError: no opencv-245 in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at ImageProc.Test.main(Test.java:14)

ImageProc.Test.main(Test.java:14)

for configure,i do this work: 1-extract work:

  1. extract the opencv file in location c: 2-open c:
  2. open eclipse and create a project 3-and then
  3. open the properties and go to java build path 4-click path
  4. click on the add library button ,then select user library ,click library, click user library ,click library, click new and and create a new library with this name opencv.245 5-add opencv-245 jar opencv.245
  5. add opencv-245.jar file with click on add external jar file button 6-and file button
  6. and for native library location :edit edit this and set this directory for this: c:/opencv/build/java/x64 7-and then click finsih

    c:/opencv/build/java/x64
  7. click finsih

i run this code and appear this exception please help me