I think I have solved the issue. It turns out that if I simply set a render bin
index on all my nodes that contain an osgText, things work as expected.
Surprisingly I don't need to set the osg::StateSet::OVERRIDE_RENDERBIN_DETAILS.
I would assume this is normal behavior. I think my main error wa
stefan nortd wrote:
> How does this look like ...
I would put the StateSet with the override flag all the way at the
topmost Group in your UI, above all the Text and above all the other
geometry you're drawing with the text.
> The one drawable is the osgText. I am also :O new to writing osg
How does this look like ...
Code:
PositionAttitudeTransform {
UniqueID PositionAttitudeTransform_15
nodeMask 0x
cullingActive TRUE
StateSet {
UniqueID StateSet_16
rendering_hint DEFAULT_BIN
renderBinMode INHERIT
GL_LIGHTING OFF
Better idea -- Write out the subgraph that draws your text -- and also
contains the override render bin bit, to a .osg file and post here or
email me. I'll take a look to see if the render bin details are set
correctly.
-Paul
Paul Martz wrote:
Are you setting this StateSet on the parent G
Are you setting this StateSet on the parent Group or Geode above all
your Text? If so, it should work. If it's not working, then this should
be investigated and resolved. I'd advise creating a very simple scene
graph that appears to reproduce the behavior, and stepping through the
CullVisitor t
Thanks Paul, Jeremy,
So after some contemplation I am pretty sure I want to use the painter's
layering. The reason is that if for example I want to rotate a panel in
front of another one I don't want it to intersect with panals behind it. I
could use orthographic projection and dynamically cha
stefan nortd wrote:
It would mean to layer the panels
close together so their size is not affected and still far enough away from
each other to not run into depth buffer resolution issues.
Is there a reason you are using a perspective projection? This would not
be an issue with an orthograph
Hey Paul, Jeremy,
So, text is in the transparent RenderBin. Hmm that makes sense. I was
hoping there is simple explanation. I guess I could use depth testing. The
main problem I had with this was to come up with a fairly simple
algorithm to determine the z position. It would mean to layer the p
osgText::Text uses a font texture map with alpha values to encode the
glyph, and text is drawn as a textured quad with blending enabled.
Because of the use of alpha and blending, osgText::Text implicitly
places text quad geometry in the transparent RenderBin. This is what you
typically want fo
On Sat, 2009-10-24 at 20:59 +, stefan nortd wrote:
> Hi,
>
> I am working on a widget system and have problems with how osgText:Text
> is layered. My text always ends up above the geometry.
>
> I have a root node that has depth testing disabled. Under it is a hierachy
> of rectangle-like p
Hi,
I am working on a widget system and have problems with how osgText:Text
is layered. My text always ends up above the geometry.
I have a root node that has depth testing disabled. Under it is a hierachy
of rectangle-like panels. Some of them have text labels. All my geometry
layers as expe
11 matches
Mail list logo