[vtkusers] custom renderwindowinteractorstyle

David Doria daviddoria at gmail.com
Thu Sep 1 11:19:39 EDT 2011


On Thu, Sep 1, 2011 at 11:16 AM, Florian Bruckner <e0425375 at gmail.com> wrote:
> ok, sounds easy, but i didn't get it running with python.
>
> i tryied the following, but the new function is never called:
>    class InteractorStyleNew(vtk.vtkInteractorStyleTrackballCamera):
>          def OnLeftButtonUp(self):
>                  print "Middle Button Pressed"
>
> seaching the net i found some other solutions:
> 1.) http://vtk.org/gitweb?p=VTK.git;a=blob;f=Examples/GUI/Python/CustomInteraction.py
> 2.) http://code.google.com/p/vtkpythonext/source/browse/trunk/spare/src/jolly/jolly_vtk2/vtkPythonInteractorStyle.py?r=35
>
> but they are not as beautiful as the method used in the c++ example.
>
>
> is there an obvious error in my example, which i cannot see, or is
> there a problem with the python support?
>
> greetings
> Florian

It would be great if you could add an example of this here:
http://www.vtk.org/Wiki/VTK/Examples/Python

once you get it working.

David



More information about the vtkusers mailing list