Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

This worked for me on version 2.4.9. I had the exact same problem trying to run the hybridtracking example

Goto opencv_contrib module->$(OPENCV_DIR)\sources\modules\contrib\src\featuretracker.cpp

Replace these lines:

#ifdef HAVE_OPENCV_NONFREE
#include "opencv2/nonfree/nonfree.hpp"

static bool makeUseOfNonfree = initModule_nonfree();
#endif

With the following:

#define HAVE_OPENCV_NONFREE
#ifdef HAVE_OPENCV_NONFREE
#include "opencv2/nonfree/nonfree.hpp"

static bool makeUseOfNonfree = cv::initModule_nonfree();
#endif