mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 18:23:54 +02:00
remove hackery for bad length units in AnimSkeleton
This commit is contained in:
parent
ee265aba4a
commit
381828dac3
1 changed files with 0 additions and 22 deletions
|
@ -26,17 +26,6 @@ AnimInverseKinematics::~AnimInverseKinematics() {
|
|||
void AnimInverseKinematics::loadDefaultPoses(const AnimPoseVec& poses) {
|
||||
_defaultRelativePoses = poses;
|
||||
assert(_skeleton && _skeleton->getNumJoints() == (int)poses.size());
|
||||
/*
|
||||
// BUG: sometimes poses are in centimeters but we expect meters.
|
||||
// HACK WORKAROUND: check for very large translation of hips and scale down as necessary
|
||||
int hipsIndex = _skeleton->nameToJointIndex("Hips");
|
||||
if (hipsIndex > -1 &&
|
||||
glm::length(_defaultRelativePoses[hipsIndex].trans) > 10.0f &&
|
||||
glm::length(_defaultRelativePoses[hipsIndex].scale) > 0.1f) {
|
||||
_defaultRelativePoses[hipsIndex].scale = glm::vec3(0.01f);
|
||||
_defaultRelativePoses[hipsIndex].trans *= 0.01f;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
void AnimInverseKinematics::loadPoses(const AnimPoseVec& poses) {
|
||||
|
@ -46,17 +35,6 @@ void AnimInverseKinematics::loadPoses(const AnimPoseVec& poses) {
|
|||
} else {
|
||||
_relativePoses.clear();
|
||||
}
|
||||
/*
|
||||
// BUG: sometimes poses are in centimeters but we expect meters.
|
||||
// HACK WORKAROUND: check for very large translation of hips and scale down as necessary
|
||||
int hipsIndex = _skeleton->nameToJointIndex("Hips");
|
||||
if (hipsIndex > -1 &&
|
||||
glm::length(_relativePoses[hipsIndex].trans) > 10.0f &&
|
||||
glm::length(_relativePoses[hipsIndex].scale) > 0.1f) {
|
||||
_relativePoses[hipsIndex].scale = glm::vec3(0.01f);
|
||||
_relativePoses[hipsIndex].trans *= 0.01f;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
void AnimInverseKinematics::computeAbsolutePoses(AnimPoseVec& absolutePoses) const {
|
||||
|
|
Loading…
Reference in a new issue