官网上:
1.Go the C++ groups General entry and underthe “Additional Include Directories” add the path to your OpenCV include.
$(OPENCV_DIR)\include
2. Next go to the Linker ‣ General and under the “Additional Library Directories” add the libs directory:
$(OPENCV_DIR)\libs
3. To do this go to the Linker ‣ Input and under the “Additional Dependencies” entry add the name of all modules which you want to use:
The names of the libraries are as follow:
opencv_(The Name of the module)(The versionNumber of the library you use)d.lib
A full list, for the currently latest trunkversion would contain:
opencv_core231d.lib
opencv_imgproc231d.lib
opencv_highgui231d.lib
opencv_ml231d.lib
opencv_video231d.lib
opencv_features2d231d.lib
opencv_calib3d231d.lib
opencv_objdetect231d.lib
opencv_contrib231d.lib
opencv_legacy231d.lib
opencv_flann231d.lib
自己做时:
1
2
3
release:
opencv_core231.lib
opencv_highgui231.lib
opencv_video231.lib
opencv_ml231.lib
opencv_legacy231.lib
opencv_imgproc231.lib
opencv_flann231.lib
opencv_features2d231.lib
opencv_calib3d231.lib
opencv_objdetect231.lib
opencv_contrib231.lib
opencv_core231d.lib
opencv_imgproc231d.lib
opencv_highgui231d.lib
opencv_ml231d.lib
opencv_video231d.lib
opencv_features2d231d.lib
opencv_calib3d231d.lib
opencv_objdetect231d.lib
opencv_contrib231d.lib
opencv_legacy231d.lib
opencv_flann231d.lib