Hi,
I have few days working with OpenCV, I started with OpenCV 2.1 and I made an object tracker with "cvMatchTemplate" function, but now I've changed to OpenCV 2.4.3 to use the "SurfFeatureDetector" function but I got this error:
main.cpp: In function ‘int main()’:
main.cpp:31:5: error: ‘SurfFeatureDetector’ was not declared in this scope
main.cpp:31:25: error: expected ‘;’ before ‘detector’
main.cpp:34:5: error: ‘detector’ was not declared in this scope
main.cpp:37:5: error: ‘SurfDescriptorExtractor’ was not declared in this scope
main.cpp:37:29: error: expected ‘;’ before ‘extractor’
main.cpp:40:5: error: ‘extractor’ was not declared in this scope
Including the following
#"opencv2/features2d/features2d.hpp"
#"opencv2/highgui/highgui.hpp"
#"opencv2/core/core.hpp"
#"opencv2/legacy/legacy.hpp" (BruteForceMatcher is defined here!)
and linking against the following
#opencv_core.so
#opencv_flann.soo (if youre using the FLANN matcher)
#opencv_highgui.so
#opencv_features2d.so
#opencv_nonfree.so
I understand that in the first part is:
#include "opencv2/features2d/features2d.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/core/core.hpp"
#include "opencv2/legacy/legacy.hpp"
but in the other part I don't know how to add them. I tried to ask in that foro but I got problem with the subscription. I'll be thankful for any help.
Thanks.