Hi, I have encountered this issue before.
>> Even so, wouldn't this just make the two spheres fight for which one was on top? Each would still be >> drawn, just not necessarily in the proper order. This is true. To get proper rendering of the transparent geometries the best approach would probably be to implement depth peeling. Have a look at the Nvidia SDK as this has some example code that implements this method. I had a quick shot at implementing this in OSG a while back. I got most of the way there but the code is long lost by now. I believe it should be relatively easy to implement using the RTT support in osgCamera and the multipass approach used by osgFX. If you do implement this I would be interested in seeing the code. Cheers, Brad -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ken Sewell Sent: Thursday, 25 May 2006 5:05 AM To: osg users Subject: Re: [osg-users] Transparency sorting. > The depth sorting is done on distance from the center of the > drawable's bounding box to the eye point. Its done purely at the > drawable level, so if indivual polygons overlap then you'll find > problems with rendering order. This isn't an OSG specific issue, but > a general real-time graphics issue associated with use of z buffers. Even so, wouldn't this just make the two spheres fight for which one was on top? Each would still be drawn, just not necessarily in the proper order. > For things like sphere's you can force the polygon ordering to be a > bit more ideal by drawing all the transparent back faces in one bin > i.e. 10, then draw all the front faces in the next bin i.e. 11. > > Robert. > > On 5/24/06, Ken Sewell <[EMAIL PROTECTED]> wrote: > > > > How exactly does OSG do transparency sorting? I have an application > > in which there are several locations that have concentric spheres. > > Each sphere has a color with an alpha of ~0.3, has BLEND and > > TRANSPARENT_BIN set in its stateset. I am encountering two issues: > > > > - I always see the outer spheres, but the inner spheres 'pop' in and > > out as the camera moves through the scene. They're there for a few > > seconds, change camera angle and they disappear, change again and they are back. > > > > - When two spheres overlap, sometimes I only see one sphere and it > > seems to be clipping the other, instead of rendering the overlapping > > part of both. > > > > - I am creating my own geode/drawable (which I haven't done much) is > > a bounding box/sphere automatically created or do I need to manually > > add one? > > > > Any ideas about what I might be doing wrong? > > > > > > Ken Sewell > > _______________________________________________ > > osg-users mailing list > > [email protected] > > http: //openscenegraph.net/mailman/listinfo/osg-users > > http: //www.openscenegraph.org/ > > > _______________________________________________ > osg-users mailing list > [email protected] > http: //openscenegraph.net/mailman/listinfo/osg-users > http: //www.openscenegraph.org/ > > _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/ DISCLAIMER:--------------------------------------------------------------------------- This Email may contain confidential and/or privileged information and is intended solely for the addressee(s) named. If you have received this information in error, or are advised that you have been posted this Email by accident, please notify the sender by return Email, do not redistribute it, delete the Email and keep no copies. -------------------------------------------------------------------------------------- _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
