[osg-users] Transparency problem

Zach Deedler mynamezach at gmail.com
Fri Sep 28 08:16:09 PDT 2007


If you set the render bins correctly, you can fix the problem.

-----Original Message-----
From: osg-users-bounces at lists.openscenegraph.org
[mailto:osg-users-bounces at lists.openscenegraph.org] On Behalf Of Paul Melis
Sent: Friday, September 28, 2007 9:52 AM
To: OpenSceneGraph Users
Subject: Re: [osg-users] Transparency problem

Paul Melis wrote:

>Panagiotis Papadakos wrote:
>
>  
>
>>Hi again!
>>
>>Well I don't think that RenderBins can help me with this. My problem is 
>>probably due to the fact that I use transparent objects that are too close

>>to each other (0.1f). That is probably why if I move the camera around, 
>>some times things are rendered correctly!
>> 
>>
>>    
>>
>That sounds more like a problem related to sorting: the sorted order 
>changes as you move the camera.
>Have you tried assigning a separate render-bin to each of the text 
>layers? That should give you a correct rendering from at least one side 
>of layers.
>  
>
Provided that you set the order of the layers correctly, of course...
Paul

>Paul
>
>  
>
>>	Panagiotis Papadakos
>>
>>On Fri, 28 Sep 2007, Andreas.Richter at dlr.de wrote:
>>
>> 
>>
>>    
>>
>>>>Well I have already tried to change the stateset of the geode of the
>>>>osgText for example with something like
>>>>
>>>>stateSetGeode->setRenderBinDetails(15, "RenderBin",
>>>>osg::StateSet::OVERRIDE_RENDERBIN_DETAILS)
>>>>
>>>>, but it doesn't seem to help. The bigger the renderbin the
>>>>later it is rendered in the scene, right?
>>>>     
>>>>
>>>>        
>>>>
>>>Yes, the foremost object have to get the highest binNumber. In my case I
>>>only have to set these number like below and it works fine for me with
>>>static objects:
>>>
>>>	osg::StateSet *stateSet = new osg::StateSet;
>>>
>>>	// specify when object is going to be drawn
>>>	stateSet->setBinNumber(99);
>>>
>>>	object->setStateSet(stateSet);
>>>
>>>I don't know if this works with HUDs. May be you also have to set the
>>>binNumber for the HUD. Perhaps the problem lies elsewhere and someone
>>>else can help.
>>>-- 
>>>Andreas Richter
>>>_______________________________________________
>>>osg-users mailing list
>>>osg-users at lists.openscenegraph.org
>>>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>>
>>>   
>>>
>>>      
>>>
>>_______________________________________________
>>osg-users mailing list
>>osg-users at lists.openscenegraph.org
>>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>> 
>>
>>    
>>
>
>_______________________________________________
>osg-users mailing list
>osg-users at lists.openscenegraph.org
>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>  
>

_______________________________________________
osg-users mailing list
osg-users at lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org




More information about the osg-users mailing list