Hi Chris,

If you are using several cameras to create the HUD, you don't need the 
renderbins anymore for this case. Every camera will only render the scene it 
has attached (addChild). You can control the ordering as seen in the osghud 
example, with osg::Camera::setRenderOrder().

Alberto

El Jueves 23 Octubre 2008ES 16:40:53 Chris Denham escribió:
> Hi Robert,
> Hmmm, now I seem to have come full circle back to the start of this thread.
> lol.
> If I use a hud camera, don't I then have the messy problem of making it
> only render the Dragger in the scene?
> Or perhaps there is a way to get main camera to render renderbins 0-10 and
> the other camera to render renderbin 11?
> I'm new to this render bin wizardry.
> Chris.
>
> ----- Original Message -----
> From: "Robert Osfield" <[EMAIL PROTECTED]>
> To: "Chris Denham" <[EMAIL PROTECTED]>; "OpenSceneGraph Users"
> <[email protected]>
> Sent: Thursday, October 23, 2008 2:42 PM
> Subject: Re: [osg-users] The best way to make some object in a scene render
> after and infront everything else.
>
> > Hi Chris,
> >
> > If you want to clear the depth buffer then you need to use a separate
> > RenderStage rather than just a RenderBin.  A RenderStage is a special
> > RenderBin that adds the frame buffer clear prior to its traversal, and
> > any copy to image/texture operations after traversal.   By default the
> > OSG has one RenderStage per Camera.   So your case you'll want an
> > extra Camera above the subgraph you want the clear.  You may place
> > this Camera in the scene graph or in the viewer.  See the osghud
> > example.
> >
> > Robert.
> >
> > On Thu, Oct 23, 2008 at 2:30 PM, Chris Denham <[EMAIL PROTECTED]>
> >
> > wrote:
> >> Hi Robert,
> >> Excellent! That was too easy ;-) so I have a secondary question.
> >> Is there a way to get it clear the depth buffer between renderbins so I
> >> can
> >> render with depth test on? The manipulator geometry does not render
> >> correctly over itself with the depth test switched off.
> >> Cheers.
> >> Chris.
> >>
> >>> Date: Thu, 23 Oct 2008 11:24:07 +0100
> >>> From: "Robert Osfield" <[EMAIL PROTECTED]>
> >>> Subject: Re: [osg-users] The best way to make some object in a scene
> >>> render after and infront everything else.
> >>> To: "OpenSceneGraph Users" <[email protected]>
> >>> Message-ID:
> >>> <[EMAIL PROTECTED]>
> >>> Content-Type: text/plain; charset=ISO-8859-1
> >>>
> >>> Hi Chris,
> >>>
> >>> You can achieve this affect several ways but the simplicist would
> >>> probably be to state the RenderBin number of the subgraph that you
> >>> want o overlay to a high figures, something like 11 or more to draw
> >>> after the default transparent bin, then disable the depth test so the
> >>> all fragments of the dragger are drawn.
> >>>
> >>> Robert.
> >>>
> >>> On Thu, Oct 23, 2008 at 10:39 AM, Chris Denham <[EMAIL PROTECTED]>
> >>>
> >>> wrote:
> >>>> I am trying to acheive an effect whereby some geometry in a scene is
> >>>> rendered after and in front of everything else.
> >>>> What I want to be able to do is show an osgManipulator::Dragger node
> >>>> attached to an object in a scene, but show it infront of everything, I
> >>>> guess
> >>>> a bit like a HUD, but where only the Dragger is rendered on the HUD.
> >>>> For anyone that has used Maya, the effect I want is similar to the
> >>>> translation/rotation/scaling manipulators, i.e. where they can be used
> >>>> and
> >>>> seen regardless of what objects that would normally be obscuring them.
> >>>> What's the best way to implement that?
> >>>> The most obvious way seemed to me to create a HUD style postrender
> >>>> camera
> >>>> to
> >>>> render the manipulator on top of the normally rendered scene. But I'm
> >>>> not
> >>>> 100% sure how to get it to only render the manipulator in the scene.
> >>>> Do I
> >>>> need to use nodemasks, or do I need to move the manipulator into an
> >>>> empty
> >>>> HUD scene along with its local to world transform?
> >>>> Neither method seemed very elegant to me, so just wondering if
> >>>> anyone's got
> >>>> a better idea.
> >>>> Chris D.
> >>>> _______________________________________________
>
> _______________________________________________
> 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

Reply via email to