[Paraview] Plugin Basics

Michael Jackson mike.jackson at bluequartz.net
Tue Dec 2 14:54:40 EST 2008


I am trying to update my plugin creator and I am coming up against  
some issues that I am not sure how to solve because I am basically  
confused as to what is going wrong. Here is the CMakeLists.txt file  
that I generate:

project(MyPlugin)
cmake_minimum_required(VERSION 2.4)
if(COMMAND cmake_policy)
       cmake_policy(SET CMP0003 NEW)
endif(COMMAND cmake_policy)

# Configure output directories.
SET (LIBRARY_OUTPUT_PATH "${PROJECT_BINARY_DIR}/Bin"
      CACHE INTERNAL "For libraries.")
SET (EXECUTABLE_OUTPUT_PATH "${PROJECT_BINARY_DIR}/Bin"
      CACHE INTERNAL "For executables.")


# -- Set the Module Name
SET(MODULE_NAME MyPlugin)
# -- Find ParaView -----
FIND_PACKAGE(ParaView REQUIRED)
INCLUDE(${PARAVIEW_USE_FILE})
INCLUDE_DIRECTORIES(    "${CMAKE_CURRENT_BINARY_DIR}"
                         "${MyPlugin_SOURCE_DIR}/src/"
)
#-- List our source files --
#SET (SOURCES ${SOURCES} ${MyPlugin_SOURCE_DIR}/src/.cpp)
SET (SOURCES ${SOURCES} ${MyPlugin_SOURCE_DIR}/src/vtkMyReader.cpp)
#SET (SOURCES ${SOURCES} ${MyPlugin_SOURCE_DIR}/src/.cpp)


# -- Add the Plugin to ParaView -----
ADD_PARAVIEW_PLUGIN(MyPlugin "1.0"
   SERVER_MANAGER_SOURCES ${SOURCES}
   SERVER_MANAGER_XML ${MyPlugin_SOURCE_DIR}/XMLFiles/MyPlugin_pvsm.xml
   GUI_RESOURCE_FILES ${MyPlugin_SOURCE_DIR}/XMLFiles/MyPlugin_gui.xml
   )


When I run cmake and then compile the project I get:

-- Build files have been written to: /Users/mjackson/Workspace/ 
MyPlugin/Build
[ 14%] Generating vtkSMXML_MyPlugin.h
-- Generate module: MyPlugin_pvsm
[ 28%] Generating moc_MyPluginPluginImplementation.cxx
[ 42%] Generating qrc_MyPlugin.cxx
Scanning dependencies of target MyPlugin
[ 57%] Building CXX object CMakeFiles/MyPlugin.dir/ 
moc_MyPluginPluginImplementation.o
[ 71%] Building CXX object CMakeFiles/MyPlugin.dir/ 
MyPluginPluginImplementation.o
[ 85%] Building CXX object CMakeFiles/MyPlugin.dir/qrc_MyPlugin.o
[100%] Building CXX object CMakeFiles/MyPlugin.dir/ 
vtkPVPluginInit_MyPlugin.o
Linking CXX shared library Bin/libMyPlugin.dylib
[100%] Built target MyPlugin


No where in there is anything about the vtkMyReader.cpp being  
compiled. Um.. What am I missing?


Thanks
_________________________________________________________
Mike Jackson                  mike.jackson at bluequartz.net
BlueQuartz Software                    www.bluequartz.net
Principal Software Engineer                  Dayton, Ohio





More information about the ParaView mailing list