mirror of
https://github.com/lubosz/overte.git
synced 2025-04-15 19:47:38 +02:00
swap the order of checks
This commit is contained in:
parent
c07b97920e
commit
390310f822
1 changed files with 1 additions and 1 deletions
|
@ -173,7 +173,7 @@ void AnimInverseKinematics::solveWithCyclicCoordinateDescent(const std::vector<I
|
|||
glm::quat tipParentRotation = absolutePoses[pivotIndex].rot;
|
||||
|
||||
// descend toward root, pivoting each joint to get tip closer to target
|
||||
while (pivotsParentIndex != -1 && pivotIndex != _hipsIndex) {
|
||||
while (pivotIndex != _hipsIndex && pivotsParentIndex != -1) {
|
||||
// compute the two lines that should be aligned
|
||||
glm::vec3 jointPosition = absolutePoses[pivotIndex].trans;
|
||||
glm::vec3 leverArm = tipPosition - jointPosition;
|
||||
|
|
Loading…
Reference in a new issue