Re: [osg-users] osg::LOD range distance Coordinate System Question

2009-10-09 Thread Robert Osfield
Hi Sean, You are correct the range distance of LOD's are in the LOD's own local co-coordinate system. This is appropriate as you almost aways want LOD's to scale relative to a screen size, and doing the calc in local coordinate allows you to decorate subgraphs with LOD's with transforms that

Re: [osg-users] osg::LOD range distance Coordinate System Question

2009-10-09 Thread Sean Spicer
Thanks Robert, This is an odd corner-case I guess, I want the LODs to be selected based upon global distance from the eye-point. For various reasons, onscreen size is inappropriate as a selector. I think I can put together a small example/patch and send it in for review. cheers, sean

[osg-users] osg::LOD range distance Coordinate System Question

2009-10-08 Thread Sean Spicer
This may be a simple question - is the LOD range distance specified in object or world coordinates? I seems as if it should be in world coordinates, but I've got an example with numerous LOD nodes in sub-graphs, and if I sent a constant distance range in each of them (0.0, 30.0f) so that each LOD

Re: [osg-users] osg::LOD range distance Coordinate System Question

2009-10-08 Thread Sean Spicer
Studying the source a bit harder, I think the range-distance is definitely in Object (local) coordinate.  The distance calculation (osg::LOD.cpp) is: required_range = nv.getDistanceToViewPoint(getCenter(),true); where getDistanceToViewPoint is (osgUtil::CullVisitor.cpp)