OpenCV on Android Using Eclipse

23,788

Solution 1

You should download the latest OpenCV 4 Android here:

http://opencv.org/downloads.html

And read these tutorials to get you started (in this order roughly):

Introduction into Android Development

OpenCV4Android SDK

Android Development with OpenCV

OpenCV4Android Reference

Solution 2

If you want to use OPEN CV in your android apps, for example if you need to read some strings from an image in your android and you are new in using OPEN CV. Then download the pre-built OpenCV library for Android from here:
http://sourceforge.net/projects/opencvlibrary/files/opencv-android/2.3/

After downloading, import OpenCV-2.3.1 into Eclipse using File-->Import...-->General-->Existing Project Into Workspace.

In your project's properties, Under Android, add the OpenCV2.3.1 library (press Add.. on the right and select OpenCV2.3.1).

            Good luck!

Solution 3

You might want to take a look at this project: https://github.com/billmccord/OpenCV-Android

I was able to run opencv applications on my android phone with the help of this port.

Solution 4

installed the Win-superpack? I recommend getting the latest .tar, extract and use it. Worked for me.

Share:
23,788
vince88
Author by

vince88

Updated on July 07, 2020

Comments

  • vince88
    vince88 almost 4 years

    I'm having a hell of a time importing OpenCV into my Android project. I've already tried this tutorial:

    http://opencv.itseez.com/doc/tutorials/introduction/android_binary_package/android_binary_package.html

    and it did not work because Eclipse would not recognize the existing projects in the directory. So after much searching I came across this trunk:

    https://code.ros.org/svn/opencv/trunk/opencv/

    and was able to import it into my workspace in Eclipse. Eclipse now recognizes the sample projects, but now the problem is that there are no OpenCV library files. So all the calls to import different classes result in errors. Shouldn't there be a opencv.jar somewhere? I've seen various posts that mention having to build the library but unfortunately I don't have the slightest clue how to do that. I need something with step by step instructions. I'm running Windows 7 64-bit.

    Thanks!