Hi Peter,
Peter Wraae Marino wrote:
Hi Users,
trying to clarify some specs on the renderbin, perhaps someone
could help:
what I'm assuming:
-there are two default renderbins created at startup "RenderBin"
and "DepthSortedBin"
-"DepthSortedBin" is always render after "RenderBin"
-"DepthSortedBin" sorts objects from back to front
-higher renderbin number means rendering is done later
-renderbins are sorted by states
what I'm asking:
-if an object has a parent osg::Group that has been set to
"RenderBin" with a value of 10 and the object itself uses
"RenderBin" with a value of 20 then which is used?
RenderBins are nested. If a node has a bin number different from the
current render bin (or its StateSet render bin mode is set
to override), a new render bin is created and is added to the current
render bin. It become the current render bin.
So, if a node has a bin number of 20 and it is different from the
current bin number, a render bin 20 is added to the current
render bin.
-an .osg file can have renderbin values too? so if I load an
.osg file and set it to have "RenderBin" 10 do I override the renderbin
values
in the file? or are they pushed relative to my given value 10?
sometimes the .osg file consist of many renderbin values.
An osg file can contain render bin values. If you load an osg file and
set the render bin number of the root node to 10, you don't
override the render bin numbers of the nodes (or just the render bin
number of the root node). Because render bins are nested
during the scene culling, it will force the cull visitor to create a
specific render bin for the whole sub-graph.
--
Regards,
Peter Wraae Marino
www.osghelp.com
- OpenSceneGraph support site
_______________________________________________
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