From 2e11642273fa218f34524cdc1dca2bd02657550a Mon Sep 17 00:00:00 2001 From: scrawl Date: Sat, 21 Mar 2015 04:10:50 +0100 Subject: [PATCH] Fix BillboardNode overriding scale --- components/nifosg/nifloader.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/components/nifosg/nifloader.cpp b/components/nifosg/nifloader.cpp index 099288b4f..30b3c6537 100644 --- a/components/nifosg/nifloader.cpp +++ b/components/nifosg/nifloader.cpp @@ -180,7 +180,11 @@ namespace if (_referenceFrame==RELATIVE_RF) { matrix.preMult(_matrix); + osg::Vec3 scale = matrix.getScale(); matrix.setRotate(osg::Quat()); + matrix(0,0) = scale.x(); + matrix(1,1) = scale.y(); + matrix(2,2) = scale.z(); } else // absolute {