mirror of
https://github.com/lubosz/overte.git
synced 2025-08-25 00:03:18 +02:00
fix bug in mixVisibleRotationDelta()
was using a non-visible rotation
This commit is contained in:
parent
66158cb8a2
commit
25840cad49
1 changed files with 1 additions and 1 deletions
|
@ -183,7 +183,7 @@ void JointState::mixRotationDelta(const glm::quat& delta, float mixFactor, float
|
|||
void JointState::mixVisibleRotationDelta(const glm::quat& delta, float mixFactor) {
|
||||
// NOTE: delta is in model-frame
|
||||
assert(_fbxJoint != NULL);
|
||||
glm::quat targetRotation = _visibleRotationInConstrainedFrame * glm::inverse(_rotation) * delta * _rotation;
|
||||
glm::quat targetRotation = _visibleRotationInConstrainedFrame * glm::inverse(_visibleRotation) * delta * _visibleRotation;
|
||||
if (mixFactor > 0.0f && mixFactor <= 1.0f) {
|
||||
//targetRotation = safeMix(targetRotation, _fbxJoint->rotation, mixFactor);
|
||||
targetRotation = safeMix(targetRotation, _rotationInConstrainedFrame, mixFactor);
|
||||
|
|
Loading…
Reference in a new issue