Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am trying to learn image processing and obviously opencv is one of the best options. Usually synaptic does all my installing work for me so I just checked the repos. But in the repos there is only on libcv1 and it is listed as 1.0.0-6.2ubuntu1. Does that mean it is version 1.0 of opencv? Also I found this page in community wiki

https://help.ubuntu.com/community/OpenCV

It says I need to install libcv4 which is not in my repos. I also downloaded the source but it uses something called cmake, never used it before. Is it similar to make?

share|improve this question
    
Just making a note here that 9.10 support ended back in April last year. As a result, answers provided here may not be useful for users of more recent Ubuntu versions. Additionally, outdated versions of Ubuntu no longer receive updates, including important security fixes. We will gladly continue to answer any questions you have for this release, but keep in mind you may want to upgrade at some point so we can provide you with better support. –  WarriorIng64 Jan 7 '12 at 23:17

4 Answers 4

In your case you have indeed version 1.0.0 of the library.

In general when you want to develop using a library, you have to get the corresponding -dev package which contains the header files. In this case libcv-dev. It will also install the library itself, which may have different version numbers depending on the soname - no need to install it separately.

In this case there is also a opencv-doc package, which contains some example programs, and which is worth installing.

If you want to build the library itself from source, you can run sudo apt-get build-dep opencv to get all the required libraries and header files to build opencv.

Building indeed uses cmake. It is a program which generates makefiles.

share|improve this answer
    
all the things related to opencv are 1.0.0. So I would have to install it manually? –  Rick_2047 Jan 11 '11 at 13:16
    
If you want a more recent version than 1.0.0 you will have to install it manually (you could grab the source package of a more recent version and try to build that). But ask yourself if you really need the features in the last release. For libraries it is often not a very good habit to program with the latest release - which may not be supported as good as the older ones. –  johanvdw Jan 11 '11 at 14:09
    
The latest is 2.2 and 1.0.0 is like 2 years old. –  Rick_2047 Jan 11 '11 at 18:42
    
If you want the last version you should indeed install manually (or upgrade ubuntu, which has 2.0.0 in lucid(10.04) and 2.1.0 in maverick(10.10). –  johanvdw Jan 11 '11 at 18:56

Here is a tutorial for installing the latest OpenCV 2.3.1 with Netbeans 7.1 as IDE.

I don't know if it installs build-essentials by itself, but the tutorial will definitly help you.

http://ninetynine.be/blog/2012/01/setting-up-opencv-2-3-1-and-netbeans-7-1-on-ubuntu-oneiric-11-10/

share|improve this answer
    
It uses the PPA of Gijs Molenaar (Gijzelaar) as suggested in an other answer –  Ruben Jan 7 '12 at 22:27

To install OpenCV using the terminal on Ubuntu:

$ su -
# apt-get update
# apt-get install build-essential
# apt-get install libavformat-dev
# apt-get install x264 v4l-utils ffmpeg
# apt-get install libcv2.3 libcvaux2.3 libhighgui2.3 python-opencv opencv-doc libcv-dev libcvaux-dev libhighgui-dev
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.