Cannot open include file: "opencv2/opencv.hpp": No such file or directory
Niklaus28 opened this issue · 2 comments
I follow the instruction as below:
To compile on Windows open yolo_mark.sln in MSVS2019, compile it x64 & Release and run the file: x64/Release/yolo_mark.cmd. Change paths in yolo_mark.sln to the OpenCV 4.1.0 installed on your computer:
(right click on project) -> properties -> C/C++ -> General -> Additional Include Directories: C:\C:\Opencv\opencv-4.1.0\opencv-4.1.0\include
(right click on project) -> properties -> Linker -> General -> Additional Library Directories: C:\Opencv\build\x64
but the error still appear
I think you got your directories wrong. Check your opencv directories.
(right click on project) -> properties -> C/C++ -> General -> Additional Include Directories: YOUR OPENCV DIR\build\install\include
you should have the file "opencv.hpp" within your include directory
(Linker) YOUR OPENCV DIR\build\install\x64\vc16\lib
you should have the "lib" files within your linker directory.
I think you got your directories wrong. Check your opencv directories.
(right click on project) -> properties -> C/C++ -> General -> Additional Include Directories: YOUR OPENCV DIR\build\install\include
you should have the file "opencv.hpp" within your include directory(Linker) YOUR OPENCV DIR\build\install\x64\vc16\lib
you should have the "lib" files within your linker directory.
solved by copying the dll into the same directory