Hello Matthias,

In the context of intersection, the different intersectors are just used for different tasks.

If you want to pick an object by a single click, you can use a line segment. If you want to pick by drawing a box, you can use a polytope.

If you want to pick something that has an area / volume, you can use a line segment. But if you want to pick points, you'll get a hard time getting a line segment from the mouse coordinates to intersect a point, so you'd use a polytope (perhaps one that represents a 2x2 or 4x4 pixel box around the clicked point, extruded from near to far plane).

Another difference, the line segment intersector orders objects by their distance (closest intersection first), but the polytope intersector doesn't (it would be pretty hard to implement even an approximation, and even that would be slow - the polytope intersector is slow enough as it is).

So you see, the two types of intersectors lend themselves naturally to different applications. Hope this helps,

J-S
--
______________________________________________________
Jean-Sebastien Guay    jean-sebastien.g...@cm-labs.com
                               http://www.cm-labs.com/
                        http://whitestar02.webhop.org/
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to