[osg-users] setLODScale affecting near far planes?

Joseanibal Colon Ramos jcolon at email.arc.nasa.gov
Mon Sep 22 00:54:12 PDT 2008

Hi all again,

Robert: for you last question; yes, I have near/far culling enabled and
the near/far setting is compute_near_far_using_bounding_volume. If the
near far modification that is taking place should be very small, somehow I
am still getting quite significant jumps because some objects near the
camera get culled when I would not like that to happen. When I enable
culling for near/far planes, it seems like osg takes into account my
preferred near/far planes and is NOT auto-computing. It does do some re
computation as I change the LODScale. Why does this happen?

>Do you get the same behavior when viewing your database in osgviewer and
>hitting the * and / keys?
>   -Paul

Sorry Paul, but it is hard for me to say, because with osgviewer I only
notice the terrain loosing or gaining detail, but since I am unable to
dump the camera information in osgviewer I cannot compare it to my
application's printouts of near far planes, but thanks for the advice.


On Sat, September 20, 2008 1:53 am, Robert Osfield wrote:
> Hi Jose,
> The LODScale does not affect the near/far planes and certainly won't
> affect near/far plane culling if enabled.  If you have compute
> near/far planes on the camera enabled then LODScale might change the
> depth range a little as different children of LOD gets selected, but
> generally this would be very small.    Could it be that you have
> enabled near/far plane culling by not disabled the compute of the
> near/far?  Both settings are on the camera.
> Robert.
> On Fri, Sep 19, 2008 at 11:01 PM, Joseanibal Colon Ramos
> <jcolon at email.arc.nasa.gov> wrote:
>> Hi all,
>> I am getting this rather weird effect when playing with the setLODScale
>> values in my application. I have a large pagedLOD terrain, with near/far
>> planes culling mode enabled for my camera, and I am looking at a certain
>> direction in the scene. I added osg's lod scale handler so that I can
>> modify the value interactively (with the * and / keys, just like in
>> osgviewer) and it turns out that as I change that value, and I dump my
>> application's debug information, I notice the the near/far planes do not
>> remain constant, although I am not moving around the scene and I am
>> always
>> looking in the same direction. This causes problems because the clipping
>> planes change as a result of changing the LOD scale and my non-LOD
>> objects
>> beyond the planes get culled.  I don't think that the clipping planes
>> should change at all if I am not moving my camera. I should still see
>> the
>> objects that are within a constant near/far distance, and I should only
>> observe different level of detail on the LOD objects as I change the
>> scale. What am I missing here?
>> I am using osg.2.6.0 on a 64bit intel linux machine. Thanks,
>> -Jose
>> _______________________________________________
>> osg-users mailing list
>> osg-users at lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

More information about the osg-users mailing list