<div dir="ltr"><div><br>There's also an osgoit sample program that renders a subgraph (a non-transparent truck model) first, and then performs depth peeling render passes (ping-pong) of the other transparent objects. The depth buffer contents from the initial solid pass are copied via blit from one FBO to the next one. This sample code uses Frame Buffer Objects, if I remember correctly.<br><br></div>Christian<br><br></div><div class="gmail_extra"><br><div class="gmail_quote">2016-12-17 10:47 GMT+01:00 Robert Osfield <span dir="ltr"><<a href="mailto:robert.osfield@gmail.com" target="_blank">robert.osfield@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">HI Hartwig,<br>
<br>
What you describe is a multiple pass render to texture, the way one<br>
does this with the OSG is to use an osg::Camera placed as slave Camera<br>
or a Camera placed in the scene graph. The Camera has a setRederOrder<br>
method this tells the cull traversal what order to draw things in.<br>
Have a look at the osgVolume::MultipassTechnique for an example of<br>
rendering to a depth texture and then using the result in the main<br>
pass.<br>
<br>
Robert.<br>
<br>
On 17 December 2016 at 08:14, Hartwig Wiesmann<br>
<div class="HOEnZb"><div class="h5"><<a href="mailto:hartwig.wiesmann@skywind.eu">hartwig.wiesmann@skywind.eu</a>> wrote:<br>
> Hi,<br>
><br>
> sorry, my fault. I messed up the rendering order. If the sphere is rendered first, it works.<br>
><br>
> Thank you!<br>
><br>
> Cheers,<br>
> Hartwig<br>
><br>
> ------------------<br>
> Read this topic online here:<br>
> <a href="http://forum.openscenegraph.org/viewtopic.php?p=69699#69699" rel="noreferrer" target="_blank">http://forum.openscenegraph.<wbr>org/viewtopic.php?p=69699#<wbr>69699</a><br>
><br>
><br>
><br>
><br>
><br>
> ______________________________<wbr>_________________<br>
> osg-users mailing list<br>
> <a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.<wbr>openscenegraph.org</a><br>
> <a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.<wbr>org/listinfo.cgi/osg-users-<wbr>openscenegraph.org</a><br>
______________________________<wbr>_________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.<wbr>openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.<wbr>org/listinfo.cgi/osg-users-<wbr>openscenegraph.org</a><br>
</div></div></blockquote></div><br></div>