OpenCV is a popular library for computer vision and image processing , it's available for C, C++ and python , the setup i'm doing was only tested with python for a image processing project i'm working on, but i'm sure it should work for others as well.
To install OpenCV , just run the following in your ubuntu terminal (ctrl+alt+T)
sudo apt-get install libopencv-*
sudo apt-get install python-opencv
sudo apt-get install python-numpy
you will be asked your root password , type it (the cursor wont move , nor will you get asterisks as you type) , press enter and let the commands run And you should have OpenCV up and running, however , if this method fails Follow this link , I had to run both the scripts before OpenCV worked for me , so i'm sharing both the methods.