Added setting of the Text::BackdropImplementation type to USE_SHADERS when setting up shaders

This commit is contained in:
Robert Osfield
2017-09-12 19:13:01 +01:00
parent 7a50bdafe3
commit 0d5a42f635
2 changed files with 80 additions and 4 deletions

View File

@@ -147,12 +147,20 @@ struct TextSettings
font->setMaxAnisotropy(maxAnisotropy);
font->setGlyphInterval(glyphInterval);
font->setGyphTextureFeatures(glyphTextureFeatures);
text.setFont(font.get());
// text.setFont(font.get());
text.setColor(textColor);
text.setBackdropType(backdropType);
text.setBackdropOffset(backdropOffset.x(), backdropOffset.y());
text.setBackdropColor(backdropColor);
if (glyphTextureFeatures==osgText::GlyphTexture::ALL_FEATURES)
{
text.setBackdropImplementation(osgText::Text::USE_SHADERS);
}
text.setFont(font.get());
}
std::string fontFilename;