Hi Frank,

By default OSG only enables culling from the sides of the view
frustum, so doesn't doing any scene graph level culling for the far
plane.  This default is required because by default the OSG also
computes the near and far planes on each frame based on what objects
are in the view frustum.  The two defaults together mean that the if
in object is in front of the camera it will be seen regardless of size
of the scene.  This provides good out of the box experience for
majority of users.

If you don't have the compute near/far planes enabled, and define them
stricky yourself by setting the camera's projection matrix then you
can also enable the far plane culling.  The appropriate settings can
all be found in osg::CullSettings, osg::Camera inherits from this so
you can just set everything via the viewer's Camera.

Robert.

On Tue, Dec 14, 2010 at 4:03 PM, Frank Sullivan
<[email protected]> wrote:
> Hello,
>
> I can tell that my OSG-based app is doing some sort of frustum culling, 
> because if I take the camera to the edge of the scene, and I turn it such 
> that it isn't looking at anything, the frame rate jumps to 500fps. However, 
> when I turn back around to look at my scene, the frame rate drops to about 
> 60fps.
>
> One thing I found interesting, though, is that this doesn't seem to work for 
> the far plane. If I aim my camera towards the scene, and I pull back until 
> the entire scene disappears beyond the far plane, my frame rate remains at 
> about 50-60fps.
>
> Does anyone know why this is happening, and if there is a way to fix it?
>
> Thanks,
> Frank
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=34841#34841
>
>
>
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to