[vtkusers] vtkpointpicker

Matthias Zangl zangl at ism-austria.at
Thu Jul 5 11:26:49 EDT 2001


Hello out there!

I just get mad with trying the vtkpointpicker. I modified the
sliceviewer.py-example in a way, that there 's a pointpicker.

In class SliceViewer I added:

self._picker = vtkPointPicker()
self._picker.SetTolerance(0.01)
.
.
.
self._Interactor.SetPicker(self._picker)
.
.

And then I used the slide-event - only for testing purposes to fire a
pick-event.

def Slide(self,x,y):
        self._picker.Pick(x,y,0,self._Renderer)
        print x,y,self._picker.GetPointId()

But, I don't know why, the point-Id is always -1. Did I forget something to
initialize or do I've to take care on other things? Or maybe its a known
problem in the nightly build (about 2 weeks old).

bye,
Matt





More information about the vtkusers mailing list