17 #ifndef _ANIMATION_HH_
18 #define _ANIMATION_HH_
56 public:
Animation(
const std::string &_name,
double _length,
bool _loop);
63 public:
double GetLength()
const;
67 public:
void SetLength(
double _len);
71 public:
void SetTime(
double _time);
75 public:
void AddTime(
double _time);
79 public:
double GetTime()
const;
83 public:
unsigned int GetKeyFrameCount()
const;
88 public:
KeyFrame* GetKeyFrame(
unsigned int _index)
const;
96 protected:
double GetKeyFramesAtTime(
double _time,
KeyFrame **_kf1,
98 unsigned int &_firstKeyIndex)
const;
135 double _length,
bool _loop);
147 public:
void GetInterpolatedKeyFrame(
PoseKeyFrame &_kf)
const;
152 protected:
void GetInterpolatedKeyFrame(
double _time,
156 protected:
void BuildInterpolationSplines()
const;
159 private:
mutable ignition::math::Spline *positionSpline;
162 private:
mutable ignition::math::RotationSpline *rotationSpline;
177 double _length,
bool _loop);
double length
animation duration
Definition: Animation.hh:105
A numeric animation.
Definition: Animation.hh:170
bool loop
true if animation repeats
Definition: Animation.hh:114
A keyframe for a NumericAnimation.
Definition: KeyFrame.hh:88
std::string name
animation name
Definition: Animation.hh:102
double timePos
current time position
Definition: Animation.hh:108
Manages an animation, which is a collection of keyframes and the ability to interpolate between the k...
Definition: Animation.hh:50
#define GZ_COMMON_VISIBLE
Definition: system.hh:84
std::vector< KeyFrame * > KeyFrame_V
array of keyframe type alias
Definition: Animation.hh:117
A keyframe for a PoseAnimation.
Definition: KeyFrame.hh:55
A key frame in an animation.
Definition: KeyFrame.hh:37
A pose animation.
Definition: Animation.hh:128
bool build
determines if the interpolation splines need building
Definition: Animation.hh:111
KeyFrame_V keyFrames
array of key frames
Definition: Animation.hh:120