From eae5f9b95859e0dd4f6c580bfc9b6f5efc623aed Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Mon, 21 May 2018 18:14:18 +0100 Subject: [PATCH] Moved the rotation to before the scale --- src/osgText/TextBase.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/osgText/TextBase.cpp b/src/osgText/TextBase.cpp index bce1a3cd3..b4a97e66c 100644 --- a/src/osgText/TextBase.cpp +++ b/src/osgText/TextBase.cpp @@ -497,6 +497,7 @@ bool TextBase::computeMatrix(osg::Matrix& matrix, osg::State* state) const rotate_matrix.invert(temp_matrix); matrix.makeTranslate(-_offset); + matrix.postMultRotate(_rotation); if (_characterSizeMode!=OBJECT_COORDS) { @@ -551,8 +552,6 @@ bool TextBase::computeMatrix(osg::Matrix& matrix, osg::State* state) const } } - matrix.postMultRotate(_rotation); - if (_autoRotateToScreen) { matrix.postMult(rotate_matrix);