void SkeletonBlendedGeometry::calculateJointTransform(void) { //Precalculate the matrix for each joint Matrix m; for(UInt32 i(0) ; i<getNumJoints() ; ++i) { m.setValue(getBindTransformation()); m.multLeft(getInternalJointInvBindTransformations(i)); m.multLeft(getJoint(i)->getToWorld()); if( m != _JointPoseTransforms[i]) { _JointPoseTransforms[i].setValue(m); _NeedRecalc = true; } } }
Matrix SkeletonBlendedGeometry::getAbsoluteBindTransformation(UInt32 index) const { Matrix Result(getBindTransformation()); Result.mult(getInternalJointBindTransformations(index)); return Result; }