我正在尝试使用OpenCV 2.4.10配置Qt Creator(Qt 5.4.1)。我已按照此页面上的步骤操作:https://zahidhasan.wordpress.com/2014/08/19/qt-5-3-1-64-bit-mingw-windows/
我遵循了除此之外的所有步骤:
INCLUDEPATH += C:\opencv-mingw\install\include
LIBS += -L”C:/opencv-mingw/install/x64/mingw/bin”
LIBS += -lopencv_core249 -lopencv_highgui249 -lopencv_imgproc249
我把它改成了
INCLUDEPATH += C:\opencv-mingw\install\include
LIBS += -L”C:/opencv-mingw/install/x64/mingw/bin”
LIBS += -lopencv_core2410 -lopencv_highgui2410 -lopencv_imgproc2410
(因为有问题的OpenCV版本恰好是2.4.10而不是2.4.9)
然而,当我尝试构建项目时,我收到以下错误:
:-1: error: cannot find -lopencv_core2410
:-1: error: cannot find -lopencv_highgui2410
:-1: error: cannot find -lopencv_imgproc2410
显然,Qt Creator由于某种原因找不到这些库。我还没有尝试过任何代码行添加到项目中,我首先尝试确保项目能够构建,但事实并非如此。我还会注意到我没有Qt Creator或OpenCV的经验,所以对解决这个问题的任何帮助表示赞赏!