ajbee
ajbee

Reputation: 3641

Error in OpenCV Android eclipse setting up sample projects

I already watched so many tutorials online but I can't figure out what's wrong with the sample projects given by the openCv. enter image description here

I also follow the steps given in this link : sample question

The error in 15 puzzle is different from camera-calibration and color-blob-detection. enter image description here enter image description here After I deleted the error lines in JavaCameraView.java file, some of the samples start to works fine. enter image description here My ndk version is r10 and OpenCV version is 2.4.9. I hope someone can help me solve my problem. Thanks in advance!

Upvotes: 1

Views: 758

Answers (2)

ajbee
ajbee

Reputation: 3641

After some configurations, I finally figured out how to solve my problem. Here are the steps:

First: Click on every folder->Properties->Android->Delete the unknown reference then add the OpenCV library.enter image description here Second: Make sure to link the C/C++ Build by Properties-> C/C++ Build-> Then copy the file path of your ndk folderenter image description here Third:copy jni folder present in face detection or other projects then paste it to a project that don't have a jni folder.

Fourth: Change the include declaration to local library of OpenCV.mk in Android.mk file.

Ex. include C:/Dev/OpenCV-2.4.9-android-sdk/OpenCV-2.4.9-android-sdk/sdk/native/jni/OpenCV.mkenter image description here Fifth:Make sure to clean and build the project.

Finally run every project on your device. cherio!

Upvotes: 0

user4531171
user4531171

Reputation:

You can look at this sample. Basically you will just need to redirect the library to your folder

Upvotes: 1

Related Questions