#include <OgreAnimationTrack.h>
Public Member Functions | |
| AnimationTrack (Animation *parent) | |
| Constructor. | |
| AnimationTrack (Animation *parent, Node *targetNode) | |
| Constructor, associates with a Node. | |
| virtual | ~AnimationTrack () |
| unsigned short | getNumKeyFrames (void) const |
| Returns the number of keyframes in this animation. | |
| KeyFrame * | getKeyFrame (unsigned short index) const |
| Returns the KeyFrame at the specified index. | |
| Real | getKeyFramesAtTime (Real timePos, KeyFrame **keyFrame1, KeyFrame **keyFrame2, unsigned short *firstKeyIndex=0) const |
| Gets the 2 KeyFrame objects which are active at the time given, and the blend value between them. | |
| KeyFrame * | createKeyFrame (Real timePos) |
| Creates a new KeyFrame and adds it to this animation at the given time index. | |
| void | removeKeyFrame (unsigned short index) |
| Removes a KeyFrame by it's index. | |
| void | removeAllKeyFrames (void) |
| Removes all the KeyFrames from this track. | |
| KeyFrame | getInterpolatedKeyFrame (Real timeIndex) const |
| Gets a KeyFrame object which contains the interpolated transforms at the time index specified. | |
| void | apply (Real timePos, Real weight=1.0, bool accumulate=false, Real scale=1.0f) |
| Applies an animation track at a certain position to the target node. | |
| Node * | getAssociatedNode (void) const |
| Returns a pointer to the associated Node object (if any). | |
| void | setAssociatedNode (Node *node) |
| Sets the associated Node object which will be automatically affected by calls to 'apply'. | |
| void | applyToNode (Node *node, Real timePos, Real weight=1.0, bool accumulate=false, Real scale=1.0f) |
| As the 'apply' method but applies to a specified Node instead of associated node. | |
| void | setUseShortestRotationPath (bool useShortestPath) |
| Sets the method of rotation calculation. | |
| bool | getUseShortestRotationPath () const |
| Gets the method of rotation calculation. | |
| void | _keyFrameDataChanged (void) const |
| Internal method used to tell the track that keyframe data has been changed, which may cause it to rebuild some internal data. | |
| bool | hasNonZeroKeyFrames (void) const |
| Method to determine if this track has any KeyFrames which are doing anything useful - can be used to determine if this track can be optimised out. | |
| void | optimise (void) |
| Optimise the current track by removing any duplicate keyframes. | |
Protected Types | |
| typedef std::vector< KeyFrame * > | KeyFrameList |
Protected Member Functions | |
| void | buildInterpolationSplines (void) const |
Protected Attributes | |
| KeyFrameList | mKeyFrames |
| Real | mMaxKeyFrameTime |
| Animation * | mParent |
| Node * | mTargetNode |
| bool | mSplineBuildNeeded |
| SimpleSpline | mPositionSpline |
| SimpleSpline | mScaleSpline |
| RotationalSpline | mRotationSpline |
| bool | mUseShortestRotationPath |
| Defines if rotation is done using shortest path. | |
Since the most common animable object is a Node, there are options in this class for associating the track with a Node which will receive keyframe updates automatically when the 'apply' method is called.
By default rotation is done using shortest-path algorithm. It is possible to change this behaviour using setUseShortestRotationPath() method.
Definition at line 54 of file OgreAnimationTrack.h.
|
|
Definition at line 165 of file OgreAnimationTrack.h. |
|
|
Constructor.
|
|
||||||||||||
|
Constructor, associates with a Node.
|
|
|
|
|
|
Internal method used to tell the track that keyframe data has been changed, which may cause it to rebuild some internal data.
|
|
||||||||||||||||||||
|
Applies an animation track at a certain position to the target node.
|
|
||||||||||||||||||||||||
|
As the 'apply' method but applies to a specified Node instead of associated node.
|
|
|
|
|
|
Creates a new KeyFrame and adds it to this animation at the given time index.
|
|
|
Returns a pointer to the associated Node object (if any).
|
|
|
Gets a KeyFrame object which contains the interpolated transforms at the time index specified.
|
|
|
Returns the KeyFrame at the specified index.
|
|
||||||||||||||||||||
|
Gets the 2 KeyFrame objects which are active at the time given, and the blend value between them.
|
|
|
Returns the number of keyframes in this animation.
|
|
|
Gets the method of rotation calculation.
|
|
|
Method to determine if this track has any KeyFrames which are doing anything useful - can be used to determine if this track can be optimised out.
|
|
|
Optimise the current track by removing any duplicate keyframes.
|
|
|
Removes all the KeyFrames from this track.
|
|
|
Removes a KeyFrame by it's index.
|
|
|
Sets the associated Node object which will be automatically affected by calls to 'apply'.
|
|
|
Sets the method of rotation calculation.
|
|
|
Definition at line 166 of file OgreAnimationTrack.h. |
|
|
Definition at line 167 of file OgreAnimationTrack.h. |
|
|
Definition at line 168 of file OgreAnimationTrack.h. |
|
|
Definition at line 176 of file OgreAnimationTrack.h. |
|
|
Definition at line 178 of file OgreAnimationTrack.h. |
|
|
Definition at line 177 of file OgreAnimationTrack.h. |
|
|
Definition at line 175 of file OgreAnimationTrack.h. |
|
|
Definition at line 169 of file OgreAnimationTrack.h. |
|
|
Defines if rotation is done using shortest path.
Definition at line 180 of file OgreAnimationTrack.h. |
Copyright © 2000-2005 by The OGRE Team
Last modified Sun Nov 20 12:36:19 2005