Fixed mirrored distance-field text.
authorKim Motoyoshi Kalland <kim.kalland@nokia.com>
Wed, 17 Aug 2011 10:19:01 +0000 (12:19 +0200)
committerQt by Nokia <qt-info@nokia.com>
Wed, 17 Aug 2011 11:19:47 +0000 (13:19 +0200)
Change-Id: Ib80f30afc72b6ef6a9cabb604656755e0b4dfff1
Reviewed-on: http://codereview.qt.nokia.com/3089
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Yoann Lopes <yoann.lopes@nokia.com>
src/declarative/scenegraph/qsgdistancefieldglyphnode_p.cpp

index 4255da4..c81113f 100644 (file)
@@ -159,7 +159,7 @@ void QSGDistanceFieldTextMaterialShader::updateState(const RenderState &state, Q
     }
     if (state.isMatrixDirty()) {
         program()->setUniformValue(m_matrix_id, state.combinedMatrix());
-        m_matrixScale = qSqrt(state.modelViewMatrix().determinant());
+        m_matrixScale = qSqrt(qAbs(state.modelViewMatrix().determinant()));
         updateRange = true;
     }
     if (updateRange) {