[osg-users] Controlling the rendering order

2009-04-02 Thread Tanguy Fautre
Hi, When doing GUI elements in OpenGL, it's particularly useful to exactly control the rendering order. Usually, this goes like this: glDepthMask(0); glDisable(GL_DEPTH_TEST); glDisable(GL_LIGHTING); glEnable(GL_BLEND); /* Render GUI back to front */

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Robert Osfield
Hi Tanguy, The OSG sorts the objects in opaque bin to minimize state changes, this is crucial for performance - it's a pretty fundamental part to efficient rendering and standard practice in high performance graphics toolkts.. This does mean the ordering changes. You have complete control over

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Tanguy Fautre
-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Robert Osfield Sent: Thursday 02 April 2009 11:59 To: OpenSceneGraph Users Subject: Re: [osg-users] Controlling the rendering order Hi Tanguy, The OSG sorts the objects in opaque bin

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Guy
: Re: [osg-users] Controlling the rendering order Hi Robert, Do you suggest I create an additional bin type (e.g. GUI_ELEMENT_BIN) in addition to OPAQUE_BIN and TRANSPARENT_BIN, and write my own sort algorithm for those (i.e. render in the same order children appears in) ? Would

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Robert Osfield
HI Tanguy, 2009/4/2 Tanguy Fautre tang...@aristechnologies.com Do you suggest I create an additional bin type (e.g. GUI_ELEMENT_BIN) in addition to OPAQUE_BIN and TRANSPARENT_BIN, and write my own sort algorithm for those (i.e. render in the same order children appears in) ? Implicit

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Tanguy Fautre
Of Guy Sent: Thursday 02 April 2009 12:28 To: OpenSceneGraph Users Subject: Re: [osg-users] Controlling the rendering order Maybe you should look at osgWidget which handles GUI elements. Guy. מאת: osg-users-boun...@lists.openscenegraph.org [mailto:osg

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Tanguy Fautre
...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Robert Osfield Sent: Thursday 02 April 2009 12:46 To: OpenSceneGraph Users Subject: Re: [osg-users] Controlling the rendering order HI Tanguy, 2009/4/2 Tanguy Fautre tang...@aristechnologies.com Do you suggest

Re: [osg-users] Controlling the rendering order

2009-04-02 Thread Robert Osfield
*To:* OpenSceneGraph Users *Subject:* Re: [osg-users] Controlling the rendering order HI Tanguy, 2009/4/2 Tanguy Fautre tang...@aristechnologies.com Do you suggest I create an additional bin type (e.g. GUI_ELEMENT_BIN) in addition to OPAQUE_BIN and TRANSPARENT_BIN, and write my own sort