#include
#include
#include
#include
#include
using namespace cv;
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
Mat image;
image = imread("1.jpg");
// 存储为关键点
std::vector<KeyPoint> keyPoints;
// 定义特征检测
FastFeatureDetector fast(40); // 检测的阈值为40 “cv::FastFeatureDetector”: 不能实例化抽象类
// 特征点检测
fast.detect(image,keyPoints);
drawKeypoints(image, keyPoints, image, Scalar::all(255), DrawMatchesFlags::DRAW_OVER_OUTIMG);
imshow("FAST feature", image);
waitKey(0);
return a.exec();
}
error: C2259: “cv::FastFeatureDetector”: 不能实例化抽象类
error: C2664: “cv::FastFeatureDetector::FastFeatureDetector(cv::FastFeatureDetector &&)”: 无法将参数 1 从“int”转换为“const cv::FastFeatureDetector &”