[vtkusers] Intersecting a line with vtkImageData/vtkStructuredGrid cells

David Doria daviddoria at gmail.com
Mon Dec 30 15:53:24 EST 2013


On Mon, Dec 30, 2013 at 1:42 PM, Bill Lorensen <bill.lorensen at gmail.com>wrote:

> David,
>
> I don't see amything in VTK. ITK does have a LineIterator that will
> visit each cell on a finite line.
>
> Bill
>

I put my quick solution here if anyone else is interested in something like
this in the future:

http://www.vtk.org/Wiki/VTK/Examples/Cxx/ImageData/IntersectLine

As a bonus, it shows a nice way to visualize the cells of an image, and how
to deletes the cells that were hit by the line.

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20131230/62d23762/attachment.htm>


More information about the vtkusers mailing list