Hi Farshid,

I have tweaked your submission to use the osg::cloneType() method as this
template function does the cast for us.

 ~/Contributors/FarshidLashkari$ diff CullVisitor.cpp
~/OpenSceneGraph/src/osgUtil/
1568c1568
<             rtts = _rootRenderStage.valid() ?
dynamic_cast<osgUtil::RenderStage*>(_rootRenderStage->cloneType()) : new
osgUtil::RenderStage;
---
>             rtts = _rootRenderStage.valid() ?
osg::cloneType(_rootRenderStage.get()) : new osgUtil::RenderStage;


This change is now checked into OSG svn/trunk.  Could you test it out and
let me know if it works fine for your usage case.

Cheers,
Robert.


On 19 May 2015 at 17:38, Farshid Lashkari <[email protected]> wrote:

> Hi Robert,
>
> I've attached a small change to the CullVisitor class, which will use
> cloneType() on the root render stage when creating children render stages.
> This allows us to pass a custom RenderStage object to the SceneView and
> have it used for all sub-stages.
>
> Cheers,
> Farshid
>
> _______________________________________________
> osg-submissions mailing list
> [email protected]
>
> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
>
>
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org

Reply via email to