[osg-users] Antialising for text
Sebastian Messerschmidt
sebastian.messerschmidt at gmx.de
Tue Jun 26 01:29:06 PDT 2018
Hi Igor,
you might want to explicitly set the font resolution to get smoother fonts.
text->setFontResolution(128,128);
And make sure you're using an appropriate true type font.
E.g.
text->setFont("/fonts/arial.ttf");
hth,
Sebastian
> Hi.
> I tried to set sampling traits->samples = 4 but I don't see any improvement.
>
> I use text this way:
>
>
> Code:
> osg::ref_ptr<osgText::Text> text = new osgText::Text;
> text->setFont(m_font);
> text->setAxisAlignment(osgText::Text::SCREEN);
> text->setDrawMode(osgText::Text::TEXT);
> text->setAlignment(osgText::Text::LEFT_BOTTOM);
> text->setCharacterSizeMode(osgText::Text::SCREEN_COORDS);
> text->setCharacterSize(11.0);
>
>
>
>
> What do I need to do to make font smoother?
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=74166#74166
>
>
>
>
>
> _______________________________________________
> 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