0

I am trying to compile my code which uses the SIFT class from the Open CV non free module but without any success. I am using Open CV version 2.4.8. I read somewhere that non free was removed from Open CV in this version and has to be added separately? If it is true, can someone tell me how to do that? Or can someone give me suggestions how to compile the code which uses SIFT class?

Muhammad Omer
  • 543
  • 1
  • 8
  • 15
  • Did you check whether the lib files exist on your harddrive? Afaik the lib exists in precompiled visual studio libs but might be in a separate folder. And to access it its not enough to include the basic opencv header, you have to include the nonfree headers manually. Do you get compile or link errors btw? – Micka Dec 06 '14 at 13:39
  • I am on Ubuntu 14.04. I get compile error. It says error: ‘SIFT’ is not a member of ‘cv’. I checked the opencv2 folder in my usr/include/ and did a grep -R "SIFT" and did not get any results. I think the files are not on my computer? Any idea how can i get them? – Muhammad Omer Dec 06 '14 at 13:42
  • how did you install it ? it's definitely in the 2.4 src. – berak Dec 06 '14 at 13:49
  • I used 'sudo apt-get install libopencv-dev' to install it through my terminal. – Muhammad Omer Dec 06 '14 at 13:56
  • You have to include the nonfree headers. But I dont know their locations and names. Try #include or search for the headers – Micka Dec 06 '14 at 13:59
  • Try #include #include taken from http://stackoverflow.com/questions/11175794/opencv-surf-function-is-not-implemented – Micka Dec 06 '14 at 14:01
  • I tried both but they don't work. I don't have "nonfree" folder inside my opencv2 folder. – Muhammad Omer Dec 06 '14 at 14:03
  • bad luck then. get the github src, checkout the 2.4 branch and cmake/make – berak Dec 06 '14 at 14:15
  • 1
    Yes, thanks. I reinstalled open cv from sources and it works now :) – Muhammad Omer Dec 06 '14 at 15:15

0 Answers0