[vtkusers] vtkPolydata contour to image

Sara Rolfe smrolfe at u.washington.edu
Sat Mar 12 19:38:44 EST 2011


Thanks Jerome.  I actually started with a binary volume and converted  
to the polydata contour.  Sounds like this step may be unnecessary.

Can anyone point me to an example of getting an image data contour  
from a filled binary volume?  I've checked the email archives and  
haven't seen anything yet.

Thanks,
Sara

On Mar 12, 2011, at 8:55 AM, Jérôme wrote:

> Hi Sara,
> In my mind, theproblem is that your polydata sampling does not match  
> the image sampling. If you managed to get a filled binary volume  
> from your polydata surface, then you can try to compute the gradient  
> of this image. Another solution is to substract the binary volume  
> from a dilated version of the binary volume: the output will contain  
> only the contour voxels.
>
> Note, they are a lot of other solutions, but these one may be  
> implemented thanks to native VTK filters.
>
> HTH,
> Jerome
>
>
> 2011/3/12 Sara Rolfe <smrolfe at u.washington.edu>
> Hello,
>
> I have a vtkPolydata contour that I'd like to convert into image  
> data.  This is similar to the example here:
> VTK/Examples/Cxx/PolyData/PolyDataContourToImageData
>
> except that I don't want the image contour to be filled.  I thought  
> that I could get around this by using polyData->GetPoints, iterating  
> through the point list, converting to an ITK image index, and  
> assigning the image data value.  However, I get the ridge artifact  
> shown in the image I've attached.
>
> Please let me know if you have any ideas on the optimal method to  
> solve this problem.
>
> Thanks,
> Sara
>
>
>
> _______________________________________________
> 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
>
>

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


More information about the vtkusers mailing list