Where are the correct include directories for OpenCV projects using local build / self-processing OpenCV?

I am trying to debug a nasty issue where I cannot load video files in OpenCV . One suggestion is to ditch the pre-built OpenCV libraries and instead build OpenCV on the same machine as the failed project.

Here's what I'm trying to do now.

In OpenCV Quick Start on how to build applications with OpenCV inside Microsoft Visual Studio , one of the important steps is to add additional include directories to the project property sheet by opening the project property pages by navigating to Configuration Properties -> C/C++ -> General -> Additional Include Directories

. Using a pre-built distribution, I am advised to add a directory C:\OpenCV2.4.6\build\include

, and indeed, inside this directory are subdirectories opencv

and opencv2

. One of my project files (like most OpenCV projects) will be required highgui.hpp

from the line

#include "opencv2/highgui/highgui.hpp"

      

In a pre-built distribution, OpenCV highgui.hpp

ends with C:\OpenCV2.4.6\build\include\opencv2\highgui

and therefore loads correctly at compile time due to the additional include directory.

Generated with CMake and built with Visual Studio 2012 the latest version of OpenCV on my machine (albeit perhaps unsuccessfully ) I can't find highgui.hpp

. It's not in C:\Users\timregan\Documents\GitHub\opencv\build\include

(there are actually no subdirectories in it opencv

and opencv2

). It is located in C: \ opencv-2.4 \ modules \ highgui \ include \ opencv2 \ highgui.

What step, flag, etc. I missed to create the correct location on my machine? Why are subdirectories opencv

and opencv2

completely missing from C:\Users\timregan\Documents\GitHub\opencv\build\include

after I generated and built OpenCV?

(NB I am using CMake 2.8.12 and Visual Studio 2012 on a Windows 8. machine)

0


source to share


1 answer


open visual studio solution and right click on setup project and then build. include files should show up inC:\Users\timregan\Documents\GitHub\opencv\selfbuild\install



+4


source







All Articles