Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

O p en CV3 directory changes

I built OpenCV 3 on Windows for Visual Studio 2012 Pro from Itseez Github. Now I am having issues with my includes. I noticed the structure of OpenCV3's directory is different from 2.4.X.

I created a property page and added the includes specified in the official tutorial . Of course a payed attention to use the correct path in relation to where stuff is on my computer.

Still, Visual Studio could not find the includes (it worked with OpenCV 2.4.9). I modified the includes to specify the subfolders such as in
#include <core\include\opencv2\core.hpp>
instead of simply
#include <opencv2\core.hpp>

Now IntelliSense removed the error from the include section but all the objects I instantiate are underlined in red, and Visual Studio cannot find identifiers such as "imread", etc. Other errors are of the kind: "cannot open source file "opencv2/core/version.hpp"" etc.

So, maybe I have simply made a mistake or a typo somewhere, or is it that the official tutorial doesn't work with OpenCV 3 due to the change in the core-module architecture?

click to hide/show revision 2
Precisions, picture

O p en CV3 directory changesOpenCV3 build from Github

I built OpenCV 3 on Windows for Visual Studio 2012 Pro from Itseez Github. Now I am having issues with my includes. I noticed the structure of OpenCV3's directory is different from 2.4.X.

I created a property page and added the includes specified in the official tutorial . Of course a payed attention to use the correct path in relation to where stuff is on my computer.

Still, Visual Studio could not find the includes (it worked with OpenCV 2.4.9). I modified the includes to specify the subfolders such as in
#include <core\include\opencv2\core.hpp>
instead of simply
#include <opencv2\core.hpp>

Now IntelliSense removed the error from the include section but all the objects I instantiate are underlined in red, and Visual Studio cannot find identifiers such as "imread", etc. Other errors are of the kind: "cannot open source file "opencv2/core/version.hpp"" etc.

So, maybe I have simply made a mistake or a typo somewhere, or is it that the official tutorial doesn't work with OpenCV 3 due to the change in the core-module architecture?

Edit: Actually, I realize that I am unsure the compilation went that well. It seems like my "include" folder is not ok. Here is the path :
D:\OpenCV3\Build\include

and what the folder looks like:

image description