Class ManagedTransformSource
java.lang.Object
com.ardor3d.extension.animation.skeletal.blendtree.ManagedTransformSource
- All Implemented Interfaces:
BlendTreeSource
This tree source maintains its own source data, which can be modified directly using setJointXXX. This source is
meant to be used for controlling a particular joint or set of joints programatically.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetSourceData(AnimationManager manager) Returns an immutable COPY of our local source data.voidinitJointsById(AnimationClip clip, int... jointIndices) Setup transform data for specific joints on this source, using the first frame from a given clip.voidinitJointsByName(SkeletonPose pose, AnimationClip clip, String... jointNames) Setup transform data on this source, using the first frame from a specific clip and jointNames from a specific pose.booleanisActive(AnimationManager manager) Does nothing.voidresetClips(AnimationManager manager, double globalStartTime) Does nothing.voidsetJointRotation(int jointIndex, ReadOnlyQuaternion rotation) Sets a rotation to the local transformdata for a given joint index.voidsetJointScale(int jointIndex, ReadOnlyVector3 scale) Sets a scale to the local transformdata for a given joint index.voidsetJointTransformData(int jointIndex, JointData jointData) Set the local source transform data for a given joint index.voidsetJointTranslation(int jointIndex, ReadOnlyVector3 translation) Sets a translation to the local transformdata for a given joint index.voidsetSourceName(String name) booleansetTime(double globalTime, AnimationManager manager) Does nothing.
-
Constructor Details
-
ManagedTransformSource
public ManagedTransformSource()
-
-
Method Details
-
setJointTransformData
Set the local source transform data for a given joint index.- Parameters:
jointIndex- our joint index value.jointData- the joint transform data. This object is copied into the local store.
-
setJointTranslation
Sets a translation to the local transformdata for a given joint index.- Parameters:
jointIndex- our joint index value.translation- the translation to set
-
setJointScale
Sets a scale to the local transformdata for a given joint index.- Parameters:
jointIndex- our joint index value.scale- the scale to set
-
setJointRotation
Sets a rotation to the local transformdata for a given joint index.- Parameters:
jointIndex- our joint index value.rotation- the rotation to set
-
getSourceData
Returns an immutable COPY of our local source data.- Specified by:
getSourceDatain interfaceBlendTreeSource- Parameters:
manager- the manager this is being called from.- Returns:
- a map of source information from the blend tree node.
-
setTime
Does nothing.- Specified by:
setTimein interfaceBlendTreeSource- Parameters:
globalTime- our new "global" timeline time.manager- the manager this is being called from.- Returns:
- true if we found at least one active clip in the tree
-
resetClips
Does nothing.- Specified by:
resetClipsin interfaceBlendTreeSource- Parameters:
manager- the manager to use in resetting the clips.globalStartTime- the new start time to use.
-
isActive
Does nothing.- Specified by:
isActivein interfaceBlendTreeSource- Parameters:
manager- the manager this is being called from.- Returns:
- true if we found at least one active clip in the tree
-
initJointsByName
Setup transform data on this source, using the first frame from a specific clip and jointNames from a specific pose.- Parameters:
pose- the pose to sample joints fromclip- the animation clip to pull data fromjointNames- the names of the joints to find indices of.
-
initJointsById
Setup transform data for specific joints on this source, using the first frame from a given clip.- Parameters:
clip- the animation clip to pull data fromjointIndices- the indices of the joints to initialize data for.
-
getSourceName
-
setSourceName
-