[vtk-developers] import vtkmy* in Python

Mathieu Sornay msornay at gmail.com
Mon Jun 11 09:09:58 EDT 2012


Hello,

I have added some classes to VTK using the vtkMy mecanism (thanks for
providing it btw).

First, I'm not sure I have fully understood the
compilation/installation process. Here's what I do (VTK-5.8 on Debian)
:
- I copy the VTK/Example/Build/vtkMy directory in my $HOME.
- I add my .h and .cxx in the Common subdir, and add them in
Common/CMakeList.txt .
- I run "ccmake .", "make" so libvtkmyCommon.so
libvtkmyCommonPython.so and libvtkmyCommonPythonD.so are created in
the bin/ sub directory.
- I add $HOME/vtkMy/bin/ to $PATH and $LD_LIBRARY_PATH.

>From there, I'm able to compile C++ code if I use the following lines
in my CMakeList.txt (but I suppose I'm doing it wrong...)
- include_directories(~/vtkMy/Common/)
- link_directories(~/vtkMy/bin/)

I'm not, however, able to import anything into Python.

I'm sure I'm missing something really obvious here, any help would be
greatly appreciated.



More information about the vtk-developers mailing list