错误LNK2019链接assimp

时间:2015-04-21 15:50:06

标签: visual-c++ linker assimp

我试图让各种样本在VC ++ 2010中运行,并且我收到链接错误。

http://assimp.sourceforge.net/lib_html/install.html

我设置了include和library目录,将assimp.dll复制到System32并将' assimp.lib'到库依赖。

我无法弄清楚我做错了什么。

1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiTransformVecByMatrix4 referenced in function _get_bounding_box_for_node
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiMultiplyMatrix4 referenced in function _get_bounding_box_for_node
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiIdentityMatrix4 referenced in function _get_bounding_box
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiTransposeMatrix4 referenced in function _recursive_render
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiImportFile referenced in function _loadasset
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiDetachAllLogStreams referenced in function _main
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiReleaseImport referenced in function _main
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiAttachLogStream referenced in function _main
1>Sample_SimpleOpenGL.obj : error LNK2019: unresolved external symbol _aiGetPredefinedLogStream referenced in function _main
1>Debug\SimpleOpenGL_Debug.exe : fatal error LNK1120: 9 unresolved externals

1 个答案:

答案 0 :(得分:0)

将lib文件添加到Linker -> General -> Additional Library Directories,然后将assimp.lib添加到Linker -> Input -> Additional Dependencies

Reference