On 02/16/2012 08:22 AM, Sajjadul Islam wrote:
Hi,

I am going through an osg example and one point there is a statement as follows:


Code:

stateset->setRenderBinDetails(-1,"RenderBin");

When OSG traverses a scene for rendering, it organizes geometry into separate render bins. Each bin has an index and a sorting mode. When it comes time to actually draw the geometry, the render bins are traversed in order of index (lowest to highest), and the geometry in those bins are drawn after being sorted according to the sorting mode.

In this case the index of -1 means that the geometry in this bin will be drawn before the rest of the geometry (which by default goes into bin 0). "RenderBin" is the default sort order (which happens to be SORT_BY_STATE).

In this case, there must be some geometry that is required to be rendered before the rest of the scene. Since you didn't mention which osg example you were looking at, that's all I can say about it.

--"J"

_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to