[vtkusers] Newbie question regarding vtkImageTracerWidget

W. John neojohn75 at yahoo.com
Mon Jul 7 08:48:43 EDT 2008


Hi,
  I'm using the vtkImageTracerWidget to manually select a particular region of a given 2D image.  After selecting a region, I would like to create a filled/solid vtkPolyData that can be displayed over the image as an overlay image.

  a) Currently, the traced points are the input of a vtkExtrusionFilter which creates the "skirt" and converts the points to vtkPolyData.  However, when I displayed the resulting vtkPolyData using vtkPolyDataToImageStencil, the mask only contains the closed line/polygon the user selected.  What do I need to do to create a filled/solid vtkPolyData from the selected/traced points?  I tried using vtkDelaunay2D without any success.

  b) Also, how can I get a list of all the points included inside the selected region?  Currently, I'm using brute force and estimating the points/pixels within the selected region by looping through the maximum bounding box of the selected region.  I'm pretty sure there's a better way to do this.  Any ideas?

Thanks for your help!
-W. John



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20080707/c3d53822/attachment.htm>


More information about the vtkusers mailing list