17 #ifndef IGNITION_COMMON_ANIMATION_HH_ 18 #define IGNITION_COMMON_ANIMATION_HH_ 28 #include <ignition/utils/ImplPtr.hh> 30 #include <ignition/common/graphics/Export.hh> 38 class NumericKeyFrame;
50 const double _length,
const bool _loop);
54 public:
double Length()
const;
58 public:
void Length(
const double _len);
62 public:
void Time(
const double _time);
66 public:
void AddTime(
const double _time);
70 public:
double Time()
const;
74 public:
bool InterpolateX()
const;
78 public:
void SetInterpolateX(
const bool _interpolateX);
82 public:
unsigned int KeyFrameCount()
const;
92 protected:
template<
typename KeyFrameType>
93 KeyFrameType *CreateKeyFrame(
const double _time);
101 protected:
double KeyFramesAtTime(
104 unsigned int &_firstKeyIndex)
const;
107 IGN_UTILS_IMPL_PTR(dataPtr)
118 const double _length,
const bool _loop);
132 const double _length,
const bool _loop,
138 public:
PoseKeyFrame *CreateKeyFrame(
const double _time);
147 protected:
void InterpolatedKeyFrame(
const double _time,
151 protected:
void BuildInterpolationSplines();
154 IGN_UTILS_IMPL_PTR(dataPtr)
165 const double _length,
const bool _loop);
178 IGN_UTILS_IMPL_PTR(dataPtr)
190 public:
unsigned int Id()
const;
194 public:
void SetId(
unsigned int _id);
198 public:
unsigned int AnimIndex()
const;
203 public:
void SetAnimIndex(
unsigned int _index);
207 public: std::chrono::steady_clock::duration Duration()
const;
212 public:
double DistanceSoFar(
213 const std::chrono::steady_clock::duration &_time)
const;
217 public: std::chrono::steady_clock::time_point StartTime()
const;
221 public:
void SetStartTime(
222 const std::chrono::steady_clock::time_point &_startTime);
226 public: std::chrono::steady_clock::time_point EndTime()
const;
230 public:
void SetEndTime(
231 const std::chrono::steady_clock::time_point &_endTime);
235 public:
bool Translated()
const;
239 public:
void SetTranslated(
bool _translated);
248 public:
void SetWaypoints(
260 public:
void SetWaypoints(
262 _waypoints,
double _tension);
265 IGN_UTILS_IMPL_PTR(dataPtr)
Information about a trajectory for an animation (e.g., Actor) This contains the keyframe information...
Definition: Animation.hh:183
Manages an animation, which is a collection of keyframes and the ability to interpolate between the k...
Definition: Animation.hh:43
A numeric animation.
Definition: Animation.hh:158
A Time class, can be used to hold wall- or sim-time. stored as sec and nano-sec.
Definition: Time.hh:33
A pose animation.
Definition: Animation.hh:111
A key frame in an animation.
Definition: KeyFrame.hh:34
A keyframe for a NumericAnimation.
Definition: KeyFrame.hh:82
Forward declarations for the common classes.
A keyframe for a PoseAnimation.
Definition: KeyFrame.hh:52