c++ - OpenCV - segfault instantiating surf feature detector -


i using c++ implementation of opencv 2.4.6.1 ubuntu 12.10 on x86_64 architecture. have been experimenting of feature detectors. found issue while instantiating surf detector through featuredetector::create method.

i able instantiate , use free detectors such fast or brisk doing:

cv::ptr<cv::featuredetector> detector = cv::featuredetector::create("fast"); cv::ptr<cv::featuredetector> detector = cv::featuredetector::create("brisk"); 

but obtaining segmentation fault @ moment instantiate , try use non free detectors surf or sift doing:

cv::ptr<cv::featuredetector> detector = cv::featuredetector::create("surf"); cv::ptr<cv::featuredetector> detector = cv::featuredetector::create("sift"); 

nonetheless can instantiate them using directly concrete class implements them:

cv::ptr<cv::featuredetector> detector = new cv::surffeaturedetector(); cv::ptr<cv::featuredetector> detector = new cv::siftfeaturedetector(); 

i requiring hot switch detector/descriptor on runtime , though tweak system instantiate surf , sift detectors when chosen consider right way of proceeding through factory class provide instances.

i cannot figure out why occurring, in several examples on web using featuredetector factory type detectors totally legal. tried adding headers nonfree module got same result.

i appreciate insight.

call cv::initmodule_nonfree(); in main, before doing else.


Comments

Popular posts from this blog

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -

java - JavaFX 2 slider labelFormatter not being used -