[vtkusers] Ray casting and intersection point

David Doria daviddoria at gmail.com
Thu Mar 15 07:45:37 EDT 2012


On Thu, Mar 15, 2012 at 7:29 AM, wingsneak <naygniw at hotmail.com> wrote:
> Hello all..
>
> I have an urgent problem that i need to solve.
>
>  I have 2 renderers (skin and skull isosurface respectively). For some
> particular point on the inner skull surface, using it's normal, I would like
> to figure out where is the intersection on the outer skin surface.
>
> Is ray casting the better method? Or is there another more suitable one?

You should use this:
http://www.vtk.org/Wiki/VTK/Examples/Cxx/DataStructures/ModifiedBSPTree_IntersectWithLine

You have to define a line segment rather than a ray, but just move
some large distance alone your ray to create the end point of the line
segment.

David



More information about the vtkusers mailing list