Class SkeletonPose

java.lang.Object
com.ardor3d.extension.animation.skeletal.SkeletonPose
All Implemented Interfaces:
Savable

public class SkeletonPose extends Object implements Savable
Joins a Skeleton with an array of joint poses. This allows the skeleton to exist and be reused between multiple instances of poses.
  • Constructor Details

    • SkeletonPose

      public SkeletonPose(Skeleton skeleton)
      Construct a new SkeletonPose using the given Skeleton.
      Parameters:
      skeleton - the skeleton to use.
    • SkeletonPose

      protected SkeletonPose()
  • Method Details

    • getSkeleton

      public Skeleton getSkeleton()
      Returns:
      the skeleton posed by this object.
    • getLocalJointTransforms

      public Transform[] getLocalJointTransforms()
      Returns:
      an array of local space transforms for each of the skeleton's joints.
    • getGlobalJointTransforms

      public Transform[] getGlobalJointTransforms()
      Returns:
      an array of global space transforms for each of the skeleton's joints. This does not take into account any transformation of the SkeletonMesh using the pose.
    • getMatrixPalette

      public Matrix4[] getMatrixPalette()
      Returns:
      an array of global space transforms for each of the skeleton's joints.
    • addPoseListener

      public void addPoseListener(PoseListener listener)
      Register a PoseListener on this SkeletonPose.
      Parameters:
      listener - the PoseListener
    • removePoseListener

      public void removePoseListener(PoseListener listener)
      Remove a PoseListener from this SkeletonPose.
      Parameters:
      listener - the PoseListener
    • clearListeners

      public void clearListeners()
      Clear all PoseListeners registered on this SkeletonPose.
    • updateTransforms

      public void updateTransforms()
      Update the global and palette transforms of our posed joints based on the current local joint transforms.
    • setToBindPose

      public void setToBindPose()
      Update our local joint transforms so that they reflect the skeleton in bind pose.
    • firePoseUpdated

      public void firePoseUpdated()
      Notify any registered PoseListeners that this pose has been "updated".
    • makeCopy

      public SkeletonPose makeCopy()
    • getClassTag

      public Class<? extends SkeletonPose> getClassTag()
      Specified by:
      getClassTag in interface Savable
    • write

      public void write(OutputCapsule capsule) throws IOException
      Specified by:
      write in interface Savable
      Throws:
      IOException
    • read

      public void read(InputCapsule capsule) throws IOException
      Specified by:
      read in interface Savable
      Throws:
      IOException
    • initSavable

      public static SkeletonPose initSavable()