Qt5 adds opencv library to the project under MSVC debugging

Note: The environment variables need to be configured before operation.
Right-click on the project ->> add library.

Select external library.

Select lib corresponding path and corresponding file. If cross-platform operation is required, please select the required platform and

complete the .pro file under the project. automatically add the following code

if there are problems, attempts to manually add the following code segment (corresponding to its installation position):

INCLUDEPATH += $$PWD/../../../OpenCV/opencv/build/include \
               $$PWD/../../../OpenCV/opencv/build/include/opencv \
               $$PWD/../../../OpenCV/opencv/build/include/opencv2

Guess you like

Origin blog.csdn.net/Mr_Bobcp/article/details/88897757