0% found this document useful (0 votes)
104 views

Opencv 2.3.1 Installation Guide For Windows 7

The document provides instructions for installing OpenCV 2.3.1 on Windows 7 with Visual Studio 2010. It involves downloading and installing Visual Studio 2010, downloading the OpenCV binary files, extracting the files to the C drive, adding the OpenCV bin path to the system PATH variable, creating a test project in Visual Studio, configuring the project properties to include the OpenCV include and library directories, and building and running the project. Additional steps are provided to resolve errors regarding the tbb_debug.dll file.

Uploaded by

Nibir Pal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
104 views

Opencv 2.3.1 Installation Guide For Windows 7

The document provides instructions for installing OpenCV 2.3.1 on Windows 7 with Visual Studio 2010. It involves downloading and installing Visual Studio 2010, downloading the OpenCV binary files, extracting the files to the C drive, adding the OpenCV bin path to the system PATH variable, creating a test project in Visual Studio, configuring the project properties to include the OpenCV include and library directories, and building and running the project. Additional steps are provided to resolve errors regarding the tbb_debug.dll file.

Uploaded by

Nibir Pal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

OpenCV 2.3.

1 installation guide for Window 7 and VS 2010

Follow these steps to install OpenCV 2.3.1

1. Download Microsoft Visual Studio 2010 Ultimate (2.27 GB) from lan and install it. It will
take about 2 hrs.
2. Download the OpenCV-2.3.1-win-superpack.exe (124 MB) from lan or from the given link
http://sourceforge.net/projects/opencvlibrary/files/opencv-win/2.3.1/ to any directory.
3. Once the package is downloaded (pre-build binary i.e. no need of cmake build) to any
directory e.g., D directory. Select the package and right click and choose “Run as
administrator”.

3. An Extract window will pop up as shown in the figure above. Enter ‘C:\’ and click the
“Extract” button . You can select whichever drive/directory you wish to. Here C:\ assumed
default directory.
4. A folder by name “opencv” will now be created in the C:\ directory.
5. Add “C:\opencv\build\x86\vc10\bin” by going to Computer (right
click)->properties->Advanced-System settings->Advanced->Environment
variable , System variables-> PATH and restart the system.
6. Open Visual Studio 2010 and select File->new project and Visual C++ and
Win32Console Application .
7. Enter the name of the project and click OK. In the application setting select Console
application and Empty project as shown in figure.

8. Click Finish , then select the project and add a .cpp file as shown in figure below E.g.
“test.cpp”.
9. Click Add and type the code as shown in figure to display a figure. In addition, you will

observe that the


red underlined code also appears. (This is because we did not set the project properties as
yet).

10. Open Project->properties, select Active(debug), Active(win32) (note by default


they will be selected), and press Configuration properties , select VC++ directories
for Include Directories (type/select)C:\opencv\build\include\opencv;
C:\opencv\build\include; opencv is for C type declaration where as opencv2 is for
C++ wrappers, so both should be included as shown in figure. For Library Directories
select C:\opencv\build\x86\vc10\lib;
Next Select Linker ->input option and in Additional dependencies (edit…) paste the
following files:
opencv_calib3d231d.lib
opencv_contrib231d.lib
opencv_core231d.lib
opencv_features2d231d.lib
opencv_flann231d.lib
opencv_gpu231d.lib
opencv_haartraining_engined.lib
opencv_highgui231d.lib
opencv_imgproc231d.lib
opencv_legacy231d.lib
opencv_ml231d.lib
opencv_objdetect231d.lib
opencv_ts231d.lib
opencv_video231d.lib

Build the project and run.

In case an error ‘ tbb_debug.dll not found’ is flagged then:

Download the tbb zip from the link:


http://threadingbuildingblocks.org/uploads/78/174/4.0/tbb40_233oss_win.zip

Extract the zip file and open ..”\tbb40_20111130oss\bin\ia32\vc10” and search for
“tbb_debug.dll”. Copy and paste it in “C:\opencv\build\x86\vc10\bin” then run the
program.

You might also like