Suppose you have installed Microsoft VisualStudio 2010
1、 Download OpenCV 2.3.1 at http://opencv.org/downloads.html
2、Create a Win32 console application
3、 Config opencv …
3.1 Menu Project> $ProjectName Properties
3.2 Choose Configuration Manager . . . and add X64 platform
3.3 At configuration field, choose All configuration
3.3.1 At configuration properties > C/C++ > AdditionalInclude , add opencv include folders
$opencv\build\includeDirectories
$opencv\build\opencv
$opencv\build\opencv2
NOTE: $opencv is a folder thatyou have installed opencv
3.3.2 At configuration properties > Linker > Additional Library Directories ,add opencv library folder
$opencv\build\X64\vc10\lib
3.4 At configuration field, choose Debug mode
3.4.1 At configuration properties > Linker > Additional dependencies > add dependencies libraries
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
NOTE:
1 . These aforementionedfile are located at .\opencv\build\x64\vc10\lib\
2. How to extract allfilenames in a folder
“win+R” > “cmd+Enter” > cd “$folder”> type in “dir” > ‘Enter > right click choose “Mark” > Drag toselect all filename > Copy and Print
3. In Debug mode ,thelibraries name are with “d” before “.” While without “d” in Release mode
3.5 Atconfiguration field , choose Release mode
3.5.1 At configuration properties >Linker > Additional dependencies > add dependencies libraries
opencv_calib3d231.lib
opencv_contrib231.lib
opencv_core231.lib
opencv_features2d231d.lib
opencv_flann231.lib
opencv_gpu231.lib
opencv_haartraining_engine.lib
opencv_highgui231.lib
opencv_imgproc231.lib
opencv_legacy231.lib
opencv_ml231.lib
opencv_objdetect231.lib
opencv_ts231.lib
opencv_video231.lib
NOTE:
1 . These aforementionedfile are located at .\opencv\build\x64\vc10\lib\
2. How to extract allfilenames in a folder
“win+R” > “cmd+Enter” > cd “$folder”> type in “dir” > ‘Enter > right click choose “Mark” > Drag toselect all filename > Copy and Print
3. In Debug mode ,thelibraries name are with “d” before “.” While without “d” in Release mode
3.6 Add $opencv\build\x64\v10\bin to System Environment Path
Let’s Start!