Improvements to the Signed Distance Field implementation.

This commit is contained in:
Robert Osfield
2017-10-04 18:06:42 +01:00
parent d2fa7c4317
commit 2f19cd4b87
4 changed files with 166 additions and 95 deletions

View File

@@ -60,7 +60,9 @@ int GlyphTexture::compare(const osg::StateAttribute& rhs) const
int GlyphTexture::getEffectMargin(const Glyph* glyph)
{
if (_glyphTextureFeatures==GREYSCALE) return 0;
else return glyph->getFontResolution().second/4;
// else return glyph->getFontResolution().second/4;
else return osg::maximum(glyph->getFontResolution().second/6, 2u);
// else return osg::maximum(glyph->getFontResolution().second/8,1u);
}
int GlyphTexture::getTexelMargin(const Glyph* glyph)