Text-animation: fix missing encoding specification

Ensure we can pass full UTF-8 strings into text animations. Will consider
for back-port after discussion on the devel list.

Ticket-Id: https://sourceforge.net/p/flightgear/codetickets/2512/
This commit is contained in:
James Turner 2021-02-07 13:02:31 +00:00 committed by Automatic Release Builder
parent 4ba4ea5602
commit ca6c6dd6d3

View File

@ -80,7 +80,7 @@ void SGText::UpdateCallback::operator()(osg::Node * node, osg::NodeVisitor *nv )
// be lazy and set the text only if the property has changed.
// update() computes the glyph representation which looks
// more expensive than a the above string compare.
text->setText( buf );
text->setText( buf, osgText::String::ENCODING_UTF8 );
text->update();
}
traverse( node, nv );