plugin accessing fileIOFilter
Posted: Fri Feb 07, 2014 9:32 pm
Hi All,
I have created a plug-in that is trying to access AsciiFilter::LoadFromFile and AsciiFilter::SaveToFile methods.
However, when I compile my plug-in I get the following errors:
--------------------------------------------------------------------------------------------
2>------ Build started: Project: QMOD_PLUGIN_DLL, Configuration: Debug Win32 ------
2> Creating library C:/Users/amutha/Desktop/CloudComapreVS2010/qCC/plugins/qMOD/Debug/QMOD_PLUGIN_DLLd.lib and object C:/Users/amutha/Desktop/CloudComapreVS2010/qCC/plugins/qMOD/Debug/QMOD_PLUGIN_DLLd.exp
2>MODObjectTableModel.obj : error LNK2019: unresolved external symbol "public: static enum CC_FILE_ERROR __cdecl FileIOFilter::SaveToFile(class ccHObject *,char const *,enum CC_FILE_TYPES)" (?SaveToFile@FileIOFilter@@SA?AW4CC_FILE_ERROR@@PAVccHObject@@PBDW4CC_FILE_TYPES@@@Z) referenced in function "public: void __thiscall MODObjectTableModel::saveSelectedEntities(void)" (?saveSelectedEntities@MODObjectTableModel@@QAEXXZ)
2>qMOD.obj : error LNK2019: unresolved external symbol "public: static class ccHObject * __cdecl FileIOFilter::LoadFromFile(class QString const &,enum CC_FILE_TYPES,bool,bool *,class Vector3Tpl<double> *)" (?LoadFromFile@FileIOFilter@@SAPAVccHObject@@ABVQString@@W4CC_FILE_TYPES@@_NPA_NPAV?$Vector3Tpl@N@@@Z) referenced in function "protected: void __thiscall qMOD::showFiles(class QList<class MODObject *> *)" (?showFiles@qMOD@@IAEXPAV?$QList@PAVMODObject@@@@@Z)
2>C:\Users\amutha\Desktop\CloudComapreVS2010\qCC\plugins\qMOD\Debug\QMOD_PLUGIN_DLLd.dll : fatal error LNK1120: 2 unresolved externals
--------------------------------------------------------------------------------------------
I am using the latest code from github and as you can see compiling on Windows using VS2010.
My CMakeList.txt is as follows:
--------------------------------------------------------------------------------------------
cmake_minimum_required(VERSION 2.8)
#REPLACE ALL 'MOD' OCCURENCES BY YOUR PLUGIN NAME
#AND ADAPT THE CODE BELOW TO YOUR OWN NEEDS!
option( INSTALL_QMOD_PLUGIN "Check to install qMOD plugin" OFF )
if (INSTALL_QMOD_PLUGIN)
#CloudCompare 'MOD' plugin
project( QMOD_PLUGIN_DLL )
#load necessary libraries (see qPCV for an example)
#if the plugin is an 'OpenGL filter', uncomment the line below
#set( CC_OPENGL_FILTER ON BOOL)
include( ../CMakePluginTpl.cmake )
#set dependencies to necessary libraries (see qPCV for an example)
target_link_libraries( ${PROJECT_NAME} ${CMAKE_CURRENT_SOURCE_DIR}/qjson/lib/qjson.lib )
include_directories( qjson/include)
include_directories( ${CMAKE_CURRENT_SOURCE_DIR} )
endif()
--------------------------------------------------------------------------------------------
Can somebody provide any useful guidance for me to compile my plugin?
Regards,
Ankit
I have created a plug-in that is trying to access AsciiFilter::LoadFromFile and AsciiFilter::SaveToFile methods.
However, when I compile my plug-in I get the following errors:
--------------------------------------------------------------------------------------------
2>------ Build started: Project: QMOD_PLUGIN_DLL, Configuration: Debug Win32 ------
2> Creating library C:/Users/amutha/Desktop/CloudComapreVS2010/qCC/plugins/qMOD/Debug/QMOD_PLUGIN_DLLd.lib and object C:/Users/amutha/Desktop/CloudComapreVS2010/qCC/plugins/qMOD/Debug/QMOD_PLUGIN_DLLd.exp
2>MODObjectTableModel.obj : error LNK2019: unresolved external symbol "public: static enum CC_FILE_ERROR __cdecl FileIOFilter::SaveToFile(class ccHObject *,char const *,enum CC_FILE_TYPES)" (?SaveToFile@FileIOFilter@@SA?AW4CC_FILE_ERROR@@PAVccHObject@@PBDW4CC_FILE_TYPES@@@Z) referenced in function "public: void __thiscall MODObjectTableModel::saveSelectedEntities(void)" (?saveSelectedEntities@MODObjectTableModel@@QAEXXZ)
2>qMOD.obj : error LNK2019: unresolved external symbol "public: static class ccHObject * __cdecl FileIOFilter::LoadFromFile(class QString const &,enum CC_FILE_TYPES,bool,bool *,class Vector3Tpl<double> *)" (?LoadFromFile@FileIOFilter@@SAPAVccHObject@@ABVQString@@W4CC_FILE_TYPES@@_NPA_NPAV?$Vector3Tpl@N@@@Z) referenced in function "protected: void __thiscall qMOD::showFiles(class QList<class MODObject *> *)" (?showFiles@qMOD@@IAEXPAV?$QList@PAVMODObject@@@@@Z)
2>C:\Users\amutha\Desktop\CloudComapreVS2010\qCC\plugins\qMOD\Debug\QMOD_PLUGIN_DLLd.dll : fatal error LNK1120: 2 unresolved externals
--------------------------------------------------------------------------------------------
I am using the latest code from github and as you can see compiling on Windows using VS2010.
My CMakeList.txt is as follows:
--------------------------------------------------------------------------------------------
cmake_minimum_required(VERSION 2.8)
#REPLACE ALL 'MOD' OCCURENCES BY YOUR PLUGIN NAME
#AND ADAPT THE CODE BELOW TO YOUR OWN NEEDS!
option( INSTALL_QMOD_PLUGIN "Check to install qMOD plugin" OFF )
if (INSTALL_QMOD_PLUGIN)
#CloudCompare 'MOD' plugin
project( QMOD_PLUGIN_DLL )
#load necessary libraries (see qPCV for an example)
#if the plugin is an 'OpenGL filter', uncomment the line below
#set( CC_OPENGL_FILTER ON BOOL)
include( ../CMakePluginTpl.cmake )
#set dependencies to necessary libraries (see qPCV for an example)
target_link_libraries( ${PROJECT_NAME} ${CMAKE_CURRENT_SOURCE_DIR}/qjson/lib/qjson.lib )
include_directories( qjson/include)
include_directories( ${CMAKE_CURRENT_SOURCE_DIR} )
endif()
--------------------------------------------------------------------------------------------
Can somebody provide any useful guidance for me to compile my plugin?
Regards,
Ankit