Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

the problem is NOT with the opencv libraries, but you to run outdated, opencv2.4 based code.

api has changed a bit with 3.x, you'll have to adapt :

  • -lopencv_xfeatures2d, NOT -lopencv_nonfree (does no more exist)
  • Ptr<xfeatures2d::SURF> surf = xfeatures2d::SURF::create() , not SURF() (you have to use that smart pointer)

    surf->detect(image, keypoints) (pointer access for all functions)

also make sure, to #include <vector> and (at least) using std::vector;

here's the docs

the problem is NOT with the opencv libraries, but you try to run outdated, opencv2.4 based code.

api has changed a bit with 3.x, you'll have to adapt :

  • -lopencv_xfeatures2d, NOT -lopencv_nonfree (does no more exist)
  • Ptr<xfeatures2d::SURF> surf = xfeatures2d::SURF::create() , not SURF() (you have to use that smart pointer)

    surf->detect(image, keypoints) (pointer access for all functions)

also make sure, to #include <vector> and (at least) using std::vector;

here's the docs