public override void AddPose(Pose pose)
        {
            Poses.Add(pose);

            // precompute the matrix for each joint for each animation frame
            SkeletalPose p = pose as SkeletalPose;
            SkeletalPose calculatedPose = new SkeletalPose(p.MatrixArray.Length);

            // multiply each animation joint matrix by its relevant inverse bind pose joint matrix
            for (int i = 0; i < calculatedPose.MatrixArray.Length; i++)
            {
                calculatedPose[i] = Skeleton.InverseBindPose[i] * p[i];
            }

            posePoses.Add(pose.Name, calculatedPose);
        }
예제 #2
0
 public virtual void AddPose(Pose pose)
 {
     Poses.Add(pose);
 }