1 | initial version |
SIFT and SURF are patented algorithms. They are implemented in nonfree module. Nonfree module is not distributed with OpenCv4Android SDK due to legal issues. I recommend you to use other features like ORB or FREAK.
You can build OpenCV from source code. You can find instructions for developers here. SIFT or SURF can by used like any other feature detector and extractor:
FeatureDetector detector = FeatureDetector.create(FeatureDetector.ORB); // May be SIFT, SURF, etc detector.detect(mat, keypoints); DescriptorExtractor extractor = DescriptorExtractor.create(DescriptorExtractor.ORB); // May be SIFT, SURF, etc extractor.compute(mat, keypoints, features);
See javadoc for feature2d module for more details.