From 1c2f86f8b72c47e71519e060541c5d1cbb5a8d82 Mon Sep 17 00:00:00 2001 From: "Anthony J. Thibault" Date: Thu, 8 Oct 2015 17:50:22 -0700 Subject: [PATCH] Fix for sending translation for non-animated joints. Only the JointState._defaultTranslation needs to be multiplied by the unitScale in JointState::translationIsDefault(). This was incorrectly flagging some non-animated joints as animated. --- libraries/animation/src/JointState.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/animation/src/JointState.cpp b/libraries/animation/src/JointState.cpp index 28416b315d..5bc88ad57f 100644 --- a/libraries/animation/src/JointState.cpp +++ b/libraries/animation/src/JointState.cpp @@ -215,7 +215,7 @@ bool JointState::rotationIsDefault(const glm::quat& rotation, float tolerance) c } bool JointState::translationIsDefault(const glm::vec3& translation, float tolerance) const { - return glm::distance(_defaultTranslation * _unitsScale, translation * _unitsScale) < tolerance; + return glm::distance(_defaultTranslation * _unitsScale, translation) < tolerance; } glm::quat JointState::getDefaultRotationInParentFrame() const {