Re: [osg-users] using AABB instead of bounding sphere for intersection tests?

2009-04-28 Thread Peter Amstutz
Chris 'Xenon' Hanson wrote: I think the reason for the bounding spheres is that it is a very efficient-to-compute formula -- many times more efficient than AABB. Are you worried about intersection efficiency during cull phase, or during intersection testing, or where? Have you actually

Re: [osg-users] using AABB instead of bounding sphere for intersection tests?

2009-04-28 Thread Jean-Sébastien Guay
Hello Peter, I'm trying to dig into the reasons that OSG intersections might be slower, and one of the first things that I noticed was the fact that our in-house library uses only hierarchical AABBs at all levels, whereas OSG uses mostly bounding spheres until getting down to the drawable

[osg-users] using AABB instead of bounding sphere for intersection tests?

2009-04-27 Thread Peter Amstutz
Is there a way to use an axis-aligned bounding box (AABB) for the coarse bounding volume rather bounding spheres, for line segment intersections? In my application my primary geometry is made up of terrain tiles which are naturally axis aligned and buildings which tend to be rectangular

Re: [osg-users] using AABB instead of bounding sphere for intersection tests?

2009-04-27 Thread Jean-Sébastien Guay
Hello Peter, In both cases, my intuition is that even the worst-case AABB is still going to represent a much tighter bound than the best-case bounding sphere, leading to unnecessary and expensive tests against the actual geometry. Actually, the osg::Node hierarchy uses bounding spheres, but

Re: [osg-users] using AABB instead of bounding sphere for intersection tests?

2009-04-27 Thread Chris 'Xenon' Hanson
Peter Amstutz wrote: Is there a way to use an axis-aligned bounding box (AABB) for the coarse bounding volume rather bounding spheres, for line segment intersections? In my application my primary geometry is made up of terrain tiles which are naturally axis aligned and buildings which tend