A pose animation.
More...
#include <Animation.hh>
Inherits Animation.
|
| | PoseAnimation (const std::string &_name, double _length, bool _loop, double _tension=0.0) |
| | Constructor.
|
| virtual | ~PoseAnimation () |
| | Destructor.
|
| void | AddTime (double _time) |
| | Add time to the animation.
|
| PoseKeyFrame * | CreateKeyFrame (double _time) |
| | Create a pose keyframe at the given time.
|
| void | GetInterpolatedKeyFrame (PoseKeyFrame &_kf) const |
| | Get a keyframe using the animation's current time.
|
| KeyFrame * | GetKeyFrame (unsigned int _index) const |
| | Get a key frame using an index value.
|
| unsigned int | GetKeyFrameCount () const |
| | Return the number of key frames in the animation.
|
| double | GetLength () const |
| | Return the duration of the animation.
|
| double | GetTime () const |
| | Return the current time position.
|
| void | SetLength (double _len) |
| | Set the duration of the animation.
|
| void | SetTime (double _time) |
| | Set the current time position of the animation.
|
|
| bool | build |
| | determines if the interpolation splines need building
|
| KeyFrame_V | keyFrames |
| | array of key frames
|
| double | length |
| | animation duration
|
| bool | loop |
| | true if animation repeats
|
| std::string | name |
| | animation name
|
| double | timePos |
| | current time position
|
◆ KeyFrame_V
array of keyframe type alias
◆ PoseAnimation()
| PoseAnimation |
( |
const std::string & | _name, |
|
|
double | _length, |
|
|
bool | _loop, |
|
|
double | _tension = 0.0 ) |
Constructor.
- Parameters
-
| [in] | _name | String name of the animation. This should be unique. |
| [in] | _length | Length of the animation in seconds |
| [in] | _loop | True == loop the animation |
◆ ~PoseAnimation()
◆ AddTime()
| void AddTime |
( |
double | _time | ) |
|
|
inherited |
Add time to the animation.
- Parameters
-
| [in] | _time | The amount of time to add in seconds |
◆ BuildInterpolationSplines()
| void BuildInterpolationSplines |
( |
| ) |
const |
|
protected |
◆ CreateKeyFrame()
Create a pose keyframe at the given time.
- Parameters
-
| [in] | _time | Time at which to create the keyframe |
- Returns
- Pointer to the new keyframe
◆ GetInterpolatedKeyFrame() [1/2]
| void GetInterpolatedKeyFrame |
( |
double | _time, |
|
|
PoseKeyFrame & | _kf ) const |
|
protected |
Get a keyframe using a passed in time.
- Parameters
-
| [in] | _time | Time in seconds |
| [out] | _kf | PoseKeyFrame reference to hold the interpolated result |
◆ GetInterpolatedKeyFrame() [2/2]
Get a keyframe using the animation's current time.
- Parameters
-
| [out] | _kf | PoseKeyFrame reference to hold the interpolated result |
◆ GetKeyFrame()
| KeyFrame * GetKeyFrame |
( |
unsigned int | _index | ) |
const |
|
inherited |
Get a key frame using an index value.
- Parameters
-
| [in] | _index | The index of the key frame |
- Returns
- A pointer the keyframe, nullptr if the _index is invalid
◆ GetKeyFrameCount()
| unsigned int GetKeyFrameCount |
( |
| ) |
const |
|
inherited |
Return the number of key frames in the animation.
- Returns
- The number of keyframes
◆ GetKeyFramesAtTime()
| double GetKeyFramesAtTime |
( |
double | _time, |
|
|
KeyFrame ** | _kf1, |
|
|
KeyFrame ** | _kf2, |
|
|
unsigned int & | _firstKeyIndex ) const |
|
protectedinherited |
Get the two key frames that bound a time value.
- Parameters
-
| [in] | _time | The time in seconds |
| [out] | _kf1 | Lower bound keyframe that is returned |
| [out] | _kf2 | Upper bound keyframe that is returned |
| [out] | _firstKeyIndex | Index of the lower bound key frame |
- Returns
- The time between the two keyframe
◆ GetLength()
| double GetLength |
( |
| ) |
const |
|
inherited |
Return the duration of the animation.
- Returns
- Duration of the animation in seconds
◆ GetTime()
Return the current time position.
- Returns
- The time position in seconds
◆ SetLength()
| void SetLength |
( |
double | _len | ) |
|
|
inherited |
Set the duration of the animation.
- Parameters
-
| [in] | _len | The length of the animation in seconds |
◆ SetTime()
| void SetTime |
( |
double | _time | ) |
|
|
inherited |
Set the current time position of the animation.
- Parameters
-
| [in] | _time | The time position in seconds |
◆ build
|
|
mutableprotectedinherited |
determines if the interpolation splines need building
◆ keyFrames
◆ length
◆ loop
true if animation repeats
◆ name
◆ timePos
The documentation for this class was generated from the following file: