Verwendung von OpenCV in QTCreator (Verknüpfungsproblem)C++

Programme in C++. Entwicklerforum
Anonymous
 Verwendung von OpenCV in QTCreator (Verknüpfungsproblem)

Post by Anonymous »

Ich habe ein Problem mit dem einfachsten Testprogramm zur Verknüpfung in QTCreator:

CODE:

Code: Select all

#include 
#include 

#include 
#include 

using namespace cv;

int _tmain(int argc, _TCHAR* argv[])
{
cv::Mat M(7,7,CV_32FC2,Scalar(1,3));
return 0;
}

Code: Select all

.pro
Datei:

Code: Select all

QT       -= gui
TARGET    = testopencv
CONFIG   += console
CONFIG   -= app_bundle
INCLUDEPATH += C:/OpenCV2_1/include/opencv
TEMPLATE = app

LIBS += C:/OpenCV2_1/lib/cxcore210d.lib \
C:/OpenCV2_1/lib/cv210d.lib \
C:/OpenCV2_1/lib/highgui210d.lib\
C:/OpenCV2_1/lib/cvaux210d.lib
SOURCES += main.cpp
Ich habe versucht, -L und -l wie LIBS += -LC:/OpenCV2_1/lib -lcxcored

Und in .pro Datei:

zu verwenden

Code: Select all

QMAKE_LIBDIR += C:/OpenCV2_1/lib/Debug

LIBS += -lcxcore210d \
-lcv210d \
-lhighgui210d
Die Fehler sind wie folgt:

Code: Select all

debug/main.o:C:\griskin\test\app\testopencv/../../../../OpenCV2_1/include/opencv/cxcore.hpp:97: undefined reference to cv::format(char const*, ...)'
Könnte mir jemand helfen? Danke!

In Visual Studio funktioniert es, aber ich brauche, dass es in QTCreator funktioniert..

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post