[vtk-developers] Contour widget enhancements to follow the cursor

Karthik Krishnan karthik.krishnan at kitware.com
Wed Jan 6 06:34:03 EST 2010


Hello:

The vtkContourWidget now supports a a "FollowCursor" mode.
If this is ON, during definition, the leading node of the contour
will automatically follow the cursor, without waiting for the the
control point to be dropped. This is particularly useful when used
in conjunction with the live-wire interpolator to see the shape of
the livewired region outlined as you move the mouse cursor.

You may test it out as :

(a) Try out the live wire widget as :

  WidgetsCxxTests TestDijkstraImageGeodesicPath -D
/home/karthik/VTKData -I --FollowCursor --DisableReplay

Note that omitting the option "--FollowCursor" reverts to the older
mode. Also "--DisableReplay" disables the definition of the widget
using the testing replay mechanism allowing you to try it yourself.

OR

(b) WidgetsCxxTests TestImageActorContourWidget -D
/home/karthik/VTKData -I --DisableReplay --FollowCursor

One simply sets the widget to use this behaviour with the following API :

  widget->FollowCursorOn();


Thanks
_________________________________
karthik



More information about the vtk-developers mailing list