How to build openCV.jar?
Hello!
First: My mission is to use OpenCV to compare photos of faces, correct me if I am wrong when I say that it will be possible with OpenCV?
Second I need to use Linux as OS and Java as environment. If I am not wrong I need to "build" the opencv*.jar my self? It does not seems to be able to download from below link, right? https://opencv.org/releases.html
So I think I need to go through these steps to produce the opencv.jar file: https://docs.opencv.org/4.0.1/d7/d9f/... I do not seem to find any opencv.jar after I had execute:
BUILD_SHARED_LIBS=off
cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/usr/local ..
Do you see what I miss? Best regards Fredrik
see https://docs.opencv.org/4.0.1/d9/d52/...
please edit your question, and add the cmake output as TEXT there.
most likely, you're missing some requirement, like ant was not installed, ,etc.
Hello guys! I have done some progress but when I followed the instructions at: https://docs.opencv.org/4.0.1/d9/d52/... there seems to be something wrong any way. I got a jar named opencv-2413.jar, (I thought it would be opencv-4.0.1.jar). But when I try to compile the HelloOpenCV, the class org.opencv.imgcodecs.Imgcodecs is missing in the newly build jar-file. Could that be because of the "git checkout 2.4" the is mentioned?
Do you see what I miss? Best regards Fredrik
Hmm, hello again guys. I tried to checkout 3.4 instead and this time the class that was missing in opencv-2432.jar was available in the opencv-346.jar. But the next problem, in the example code there is a call to Imgproc.rectangle... but that method seems not to be available in the class "org.opencv.imgproc.Imgproc" (the import to this class was also missing in the example). Any clues would be helpful. Best regards Fredrik
Hello guys! I think I finally manage to build and run the example from branch 3.4. I will try to assemble a description of how I did it. Best regards Fredrik ANdersson
@fredand44 -- please do so !!
Hello @berak what do you think of this description: http://www.albinoni.se/pdf/How_I_run_... Best regards Fredrik