我想在x64 Windows 7臺式計算機上使用Visual Studios 2013,OpenCV 2.4.9和Qt 5.4運行一些代碼。當我將解決方案平臺設置爲Win32時,代碼運行良好。然而,爲了讓我繼續這個項目,我需要接下來實現微軟的Magnification API,它已經在我的計算機的本機操作系統類型上運行,因爲它有一些問題沒有得到解決。但是,當我配置的所有設置在x64上運行,我得到以下錯誤:LNK2019錯誤:在x64機器上使用x86庫
1>mainwindow.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl INTRAFACE::FaceAlignment::FaceAlignment(char const *,char const *,class INTRAFACE::XXDescriptor const *,class cv::Rect_<double> const &)" ([email protected]@@[email protected]@[email protected][email protected]@[email protected]@@Z) referenced in function "private: void __cdecl MainWindow::detect(class cv::VideoCapture,bool)" ([email protected]@@[email protected]@@[email protected])
1>mainwindow.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: enum INTRAFACE::IFRESULT __cdecl INTRAFACE::FaceAlignment::Track(class cv::Mat const &,class cv::Mat const &,class cv::Mat &,float &)" ([email protected]@[email protected]@[email protected]@[email protected]@@[email protected]@Z) referenced in function "private: void __cdecl MainWindow::detect(class cv::VideoCapture,bool)" ([email protected]@@[email protected]@@[email protected])
1>mainwindow.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: enum INTRAFACE::IFRESULT __cdecl INTRAFACE::FaceAlignment::Detect(class cv::Mat const &,class cv::Rect_<int> const &,class cv::Mat &,float &)" ([email protected]@[email protected]@[email protected]@[email protected]@@[email protected]@[email protected]@[email protected]) referenced in function "private: void __cdecl MainWindow::detect(class cv::VideoCapture,bool)" ([email protected]@@[email protected]@@[email protected])
1>mainwindow.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: enum INTRAFACE::IFRESULT __cdecl INTRAFACE::FaceAlignment::EstimateHeadPose(class cv::Mat const &,struct INTRAFACE::HeadPose &)" ([email protected]@[email protected]@[email protected]@[email protected]@@[email protected]@@Z) referenced in function "private: void __cdecl MainWindow::detect(class cv::VideoCapture,bool)" ([email protected]@@[email protected]@@[email protected])
1>mainwindow.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl INTRAFACE::FaceAlignment::~FaceAlignment(void)" ([email protected]@@[email protected]) referenced in function "private: void __cdecl MainWindow::detect(class cv::VideoCapture,bool)" ([email protected]@@[email protected]@@[email protected])
1>Q:\eyegaze\x64\Release\\EyeGazeDemo.exe : fatal error LNK1120: 5 unresolved externals
INTRAFACE :: FaceAlignment來自一個Intraface庫(即86)這是什麼導致了問題?如果是這樣,我該如何解決這個問題?
謝謝!
是的,如果您想將其作爲x64代碼運行,則需要x64版本的庫。 –
@BoPersson有沒有一種方法可以自己解決這個問題? (我不認爲有一個x64版本可供下載) –
除非你有所有的源代碼,並且可以自己構建x64版本。 –