[osg-users] Upgrading OSG and need to know....

Danklefsen, Allen M adanklefsen at alionscience.com
Tue Dec 4 09:29:51 PST 2007


Hello,

I understand the culling mode, however what I was wondering what the
getting of the renderstage and state graph to use on my custom cull
visitor.

-Allen

-----Original Message-----
From: osg-users-bounces at lists.openscenegraph.org
[mailto:osg-users-bounces at lists.openscenegraph.org] On Behalf Of Robert
Osfield
Sent: Tuesday, December 04, 2007 12:15 PM
To: OpenSceneGraph Users
Subject: Re: [osg-users] Upgrading OSG and need to know....

HI Allen,

osg::Camera is subclassed from osg::CullSettings as is SceneView so...

 
viewer.getCamera()->setCullingMode(osg::CullSettings::ENABLE_ALL_CULLING
);

I hope this makes sense :-)

Robert.

On Dec 4, 2007 4:22 PM, Danklefsen, Allen M
<adanklefsen at alionscience.com> wrote:
>
> Hello,
>
> Im upgrading my osg and came into a snag.
>
> How would I go about changing the following to work?
>
> // assume initialized
> osg::Camera* camera;
>
> osgUtil::SceneView* sceneView = camera->GetSceneView();
> mCullVisitor->setRenderStage(sceneView->getRenderStage());
> mCullVisitor->setStateGraph(sceneView->getStateGraph());
>
> int flags = osgUtil::CullVisitor::ENABLE_ALL_CULLING;
>
> mCullVisitor->setCullingMode(flags);
> sceneView->setCullingMode(flags);
> sceneView->setCullVisitor(mCullVisitor.get());
>
>
> Thanks.
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
>
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or
g
>
_______________________________________________
osg-users mailing list
osg-users at lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or
g



More information about the osg-users mailing list