本文主要是介绍error LNK2019: 无法解析的外部符号 六处错误的纠正,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
错误 18 error LNK2019: 无法解析的外部符号 "public: void __thiscall cv::FeatureDetector::detect(class cv::Mat const &,class std::vector<class cv::KeyPoint,class std::allocator<class cv::KeyPoint> > &,class cv::Mat const &)const " (?detect@FeatureDetector@cv@@QBEXABVMat@2@AAV?$vector@VKeyPoint@cv@@V?$allocator@VKeyPoint@cv@@@std@@@std@@0@Z),该符号在函数 "int * __cdecl ImageFeatureExtract(unsigned char *,int,int,int,int)" (?ImageFeatureExtract@@YAPAHPAEHHHH@Z) 中被引用 E:\IndoorLocate\code\SIFT_LLC(8.3)\SIFT_LLC(8.3)\FeatureExtract.obj SIFT_LLC(8.3)错误 20 error LNK2019: 无法解析的外部符号 "public: void __thiscall cv::DescriptorExtractor::compute(class cv::Mat const &,class std::vector<class cv::KeyPoint,class std::allocator<class cv::KeyPoint> > &,class cv::Mat &)const " (?compute@DescriptorExtractor@cv@@QBEXABVMat@2@AAV?$vector@VKeyPoint@cv@@V?$allocator@VKeyPoint@cv@@@std@@@std@@AAV32@@Z),该符号在函数 "int * __cdecl ImageFeatureExtract(unsigned char *,int,int,int,int)" (?ImageFeatureExtract@@YAPAHPAEHHHH@Z) 中被引用 E:\IndoorLocate\code\SIFT_LLC(8.3)\SIFT_LLC(8.3)\FeatureExtract.obj SIFT_LLC(8.3)
错误 19 error LNK2019: 无法解析的外部符号 "public: static class cv::Ptr<class cv::FeatureDetector> __cdecl cv::FeatureDetector::create(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (?create@FeatureDetector@cv@@SA?AV?$Ptr@VFeatureDetector@cv@@@2@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z),该符号在函数 "int * __cdecl ImageFeatureExtract(unsigned char *,int,int,int,int)" (?ImageFeatureExtract@@YAPAHPAEHHHH@Z) 中被引用 E:\IndoorLocate\code\SIFT_LLC(8.3)\SIFT_LLC(8.3)\FeatureExtract.obj SIFT_LLC(8.3)
错误 21 error LNK2019: 无法解析的外部符号 "public: static class cv::Ptr<class cv::DescriptorExtractor> __cdecl cv::DescriptorExtractor::create(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (?create@DescriptorExtractor@cv@@SA?AV?$Ptr@VDescriptorExtractor@cv@@@2@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z),该符号在函数 "int * __cdecl ImageFeatureExtract(unsigned char *,int,int,int,int)" (?ImageFeatureExtract@@YAPAHPAEHHHH@Z) 中被引用 E:\IndoorLocate\code\SIFT_LLC(8.3)\SIFT_LLC(8.3)\FeatureExtract.obj SIFT_LLC(8.3)
错误 22 error LNK2019: 无法解析的外部符号 "bool __cdecl cv::initModule_nonfree(void)" (?initModule_nonfree@cv@@YA_NXZ),该符号在函数 "int * __cdecl ImageFeatureExtract(unsigned char *,int,int,int,int)" (?ImageFeatureExtract@@YAPAHPAEHHHH@Z) 中被引用 E:\IndoorLocate\code\SIFT_LLC(8.3)\SIFT_LLC(8.3)\FeatureExtract.obj SIFT_LLC(8.3)
错误 23 error LNK1120: 5 个无法解析的外部命令 E:\IndoorLocate\code\SIFT_LLC(8.3)\Debug\SIFT_LLC(8.3).exe 1 1 SIFT_LLC(8.3)
纠正方法:
缺少了库函数。在连接器--输入--附加依赖项里面加上两个库:opencv_nonfree249d.lib opencv_features2d249d.lib
249处是自己的OpenCV对用版本
这篇关于error LNK2019: 无法解析的外部符号 六处错误的纠正的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!