mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 09:48:44 +02:00
fix for clearJointData() in JS scripts
let the JointState class verify animation priority
This commit is contained in:
parent
3fbbeecb8c
commit
6cdee21a50
1 changed files with 4 additions and 6 deletions
|
@ -708,7 +708,6 @@ void Model::clearJointAnimationPriority(int index) {
|
|||
void Model::setJointState(int index, bool valid, const glm::quat& rotation, float priority) {
|
||||
if (index != -1 && index < _jointStates.size()) {
|
||||
JointState& state = _jointStates[index];
|
||||
if (priority >= state._animationPriority) {
|
||||
if (valid) {
|
||||
state.setRotationInConstrainedFrame(rotation, priority);
|
||||
} else {
|
||||
|
@ -716,7 +715,6 @@ void Model::setJointState(int index, bool valid, const glm::quat& rotation, floa
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int Model::getParentJointIndex(int jointIndex) const {
|
||||
return (isActive() && jointIndex != -1) ? _geometry->getFBXGeometry().joints.at(jointIndex).parentIndex : -1;
|
||||
|
|
Loading…
Reference in a new issue