From 7882c3d7f05565409672870089b7c16af16e8619 Mon Sep 17 00:00:00 2001 From: scrawl Date: Wed, 20 May 2015 03:38:40 +0200 Subject: [PATCH] Fix incorrect rotation for meshes with BoneOffset --- components/sceneutil/attach.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/sceneutil/attach.cpp b/components/sceneutil/attach.cpp index 49e2acbd2..2432b5eb2 100644 --- a/components/sceneutil/attach.cpp +++ b/components/sceneutil/attach.cpp @@ -82,7 +82,7 @@ namespace SceneUtil trans = new osg::PositionAttitudeTransform; trans->setPosition(boneOffset->getMatrix().getTrans()); // The BoneOffset rotation seems to be incorrect - trans->setAttitude(osg::Quat(-90, osg::Vec3f(1,0,0))); + trans->setAttitude(osg::Quat(osg::DegreesToRadians(-90.f), osg::Vec3f(1,0,0))); } if (attachNode.find("Left") != std::string::npos)