[vtkusers] Problem of vtkPointWidget test
Florian Bruckner
e0425375 at gmail.com
Thu Sep 8 15:56:14 EDT 2011
ok, this is simple. you don't even have to define a picker, because
your pointWidget is by default "pickable". And you also have already
defined an observer for the interactionEvent. Just adding
print obj.GetPosition() to the ProbeData(obj, event) function prints
the current position of the widget every time it is moved.
bye
FloB
On Thu, Sep 8, 2011 at 8:54 PM, Xiaopeng Yang <yxp233 at postech.ac.kr> wrote:
> Thanks very much. It works. I put the setposition after placewidget().
>
> By the way, do you think whether I can use a picker in the interaction to
> pick up the position of a point that I move to a new place?
>
> Best,
> Xiaopeng
>
> -----Original Message-----
> From: Florian Bruckner [mailto:e0425375 at gmail.com]
> Sent: Friday, September 09, 2011 3:10 AM
> To: Xiaopeng Yang
> Cc: vtk
> Subject: Re: [vtkusers] Problem of vtkPointWidget test
>
> just tried it and adding a simple pointWidget.SetPosition(10,0,0)
> solves the problem.
>
> perhaps you called called pointWidget.PlaceWidget() after
> SetPosition() which then resets the position to the center of the
> geometry!?
>
> hth
> FloB
>
>
> On Thu, Sep 8, 2011 at 7:57 PM, Xiaopeng Yang <yxp233 at postech.ac.kr> wrote:
>> Dear Users,
>>
>>
>>
>> I tried the testing code about vtkPointWidget and found that no matter
> where
>> I change the point location the initial 3D cross is always at the same
>> position, not at the point. Do you guys know what's wrong here? How to
> make
>> the initial cross located at the point?
>>
>>
>>
>> Thanks a lot,
>>
>> Xiaopeng
>>
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the VTK FAQ at:
>> http://www.vtk.org/Wiki/VTK_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.vtk.org/mailman/listinfo/vtkusers
>>
>>
>
>
>
>
>
>
>
>
More information about the vtkusers
mailing list