In function keypoint_calc(cv::Mat)':
FilePath/MyFirstOpenCVJNI-master/jni/first-opencvjni.cpp:35: undefined reference to
cv::xfeatures2d::SIFT::create(int, int, double, double, double)'
./obj/local/arm64-v8a/objs/first-opencvjni/first-opencvjni.o: In function sift_descriptor(cv::Mat, std::vector<cv::KeyPoint, std::allocator<cv::KeyPoint> >)':
FilePath/MyFirstOpenCVJNI-master/jni/first-opencvjni.cpp:45: undefined reference to
cv::xfeatures2d::SIFT::create(int, int, double, double, double)'
#include <jni.h>
#include <opencv2/core/core.hpp>
#include <opencv2/imgproc/imgproc_c.h>
#include <opencv/cv.h>
#include <opencv2/opencv.hpp>
#include <GLES2/gl2.h>
#include <android/log.h>
#include <opencv2/flann/flann.hpp>
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/calib3d/calib3d.hpp"
#include "opencv2/nonfree/nonfree.hpp"
#include "opencv2/nonfree/features2d.hpp"
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/xfeatures2d.hpp>
#include <iostream>
#define LOG_TAG "cpp-file"
are my includes.
And on those mentioned lines i have following code.
cv::Ptr<cv::xfeatures2d::SIFT> feature_detector = cv::xfeatures2d::SIFT::create(200);
and
cv::Ptr<cv::xfeatures2d::SIFT> feature_detector = cv::xfeatures2d::SIFT::create(200);
I'm a noob to JNI any help would be highly appreciated.