Jason Daly wrote on 2011-11-08:
> On 11/08/2011 04:51 PM, Buckley, Bob CTR MDA/DES wrote:
> I got the per state solution. But, I'm looking for fixing the
> transparency bin.
>
> Should be on that bin rather than wasting resources on
> identifying and setting on all the applicable states - transparent
> colors and textures.
>
>
> Hmm. You can set a StateSet on a RenderBin, but I'm not entirely sure
> if that would accomplish your goal or not.
>
> It's also a bit of a pain to get to the RenderBin objects from the
> Viewer, but I think it's possible:
>
> viewer.getRenderer().getSceneView(0).getRenderStage().getRenderBinList(
> ).
> find(osg::StateSet::TRANSPARENT_BIN);
> The Renderer has two SceneViews for double-buffering, so you'd have to
> do this on both.
>
> Hopefully someone will correct me if this is totally wrong :-)
I haven't tested this, but you can try modifying the StateSet on the prototype
that the transparent bin is created from:
RenderBin::getRenderBinPrototype("DepthSortedBin")->getStateSet()->...
That assumes all DepthSortedBins should have depth writes disabled, though.
Hope this helps,
--
Bryan Thrall
Principal Software Engineer
FlightSafety International
[email protected]
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org