Can you send me an example showing this? I can probably fix the problem
right up when I see the code.

However, unless you've got some FFP blending setup elsewhere in your
scene, I'm having a hard time imagining what could be wrong...

On Fri, 2011-05-27 at 23:46 +0400, Sergey Kurdakov wrote:
> Hi,
> 
> I use osgPango to render text ( latest version from svn ).
> 
> 
> from what I got from code,  first glyphs are rendered to layers, then
> default shader puts 
> everything into frontbuffer  ( default is frag1 shader - which I
> use ).
> 
> 
> However - due to use of alpha in shader the text looks somewhat not
> very crisp
> ( some parts of letters appear as if they have some alpha ( I render
>  above alpha texture but with osgPango node 
> with blend option switched off  - but still shader takes it into
> account)
> 
> 
> from shader generator  baseFragmentHeader(unsigned int num)
> 
> 
> there is a statement
> 
> 
> return vec4(c.rgb * t.a, t.a);
> 
> 
> so - naturally alpha is present in output pixel.
> 
> 
> Replacing the string
> 
> 
> to
> 
> 
> return vec4(c.rgb, t.a);
> 
> 
> does not change  much.
> 
> 
> but
> 
> 
> return vec4(c.rgb , 1.0 );
> 
> 
> renders everything outside letters  with black ( so instead of text -
> filled rectangles ).
> 
> 
> now, maybe I miss something simple
> but how to filter
> alpha so that
> I have less fuzzy letters and also do not produce non needed
> artifacts.
> 
> 
> 
> 
> Regards
> Sergey
> 
> 
> 
> 
> 
> _______________________________________________
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


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

Reply via email to