I am trying to use the Qt new functions described here: http://opencv.willowgarage.com/documentation/cpp/qt_new_functions.html#cv-createbutton
And I also found this topic on SO: openCV 2.2 createButton LNK 2019 error in Visual Studio 2010 but compiling with QT didn't work.
Anyway, according to my searches it seems to be a linking problem. My doubt is that I already compiled OpenCV (without QT) but I can use the createTrackbar normally.
I tried using the createButton as this:
cv::createButton("buttonCanny", buttonCallBackCanny,NULL,CV_RADIOBOX,true);
But I get this error:
undefined reference to `cv::createButton(std::string const&, void ()(int, void), void*, int, bool)'
I tried the cvCreateButton but I get the same error.
I have this setup C/C++ Build -> Settings -> Tool Settings -> MingGW C++ Linker -> Libraries (all the .dll from compiled OpenCV)
- libopencv_calib3d230
- opencv_ffmpeg
- libopencv_contrib230
- libopencv_core230
- libopencv_features2d230
- libopencv_flann230
- libopencv_gpu230
- libopencv_highgui230
- libopencv_imgproc230
- libopencv_legacy230
- libopencv_ml230
- libopencv_objdetect230
- libopencv_video230
C/C++ Build -> Settings -> Tool Settings -> MingGW C++ Linker -> Search Path ("C:\opencvbin\bin" where the Dll are)
C/C++ Build -> Settings -> Tool Settings -> GCC C++ Compiler -> Includes "C:\OpenCV2.3\build\include"
Any suggestions?
Thank you!