10 #include <Atoms/Globals.h>
11 #include <Atoms/AnimationClip.h>
17 class AnimationClipLooper;
43 inline bool isValid()
const;
58 inline int numJoints()
const;
64 inline unsigned int numberBlendFrames()
const;
70 inline void setNumberBlendFrames(
unsigned int value);
76 inline void setLoopStartFrame(
unsigned int value);
82 inline unsigned int loopStartFrame()
const;
88 inline void setLoopEndFrame(
unsigned int value);
94 inline unsigned int loopEndFrame()
const;
215 inline std::vector<std::string> metadataNames(
const unsigned int jointId)
const;
225 AtomsPtr<AtomsCore::Metadata>
getMetadata(
const unsigned int jointId,
const std::string &metadataName,
const double time,
const int offset = 0)
const;
235 bool getMetadataInPlace(
const unsigned int jointId,
const std::string& metadataName,
const double time, AtomsPtr<AtomsCore::Metadata>& outMeta,
const int offset = 0)
const;
247 AtomsPtr<AtomsCore::Metadata>
getMetadataAtFrame(
const unsigned int jointId,
const std::string &metadataName,
const unsigned frame,
const double reminder)
const;
258 void getMetadataAtFrameInPlace(
const unsigned int jointId,
const std::string& metadataName,
const unsigned frame,
const double reminder, AtomsPtr<AtomsCore::Metadata>& OutMeta)
const;
265 inline std::vector<std::string> staticMetadataNames(
const unsigned int jointId)
const;
272 inline AtomsPtr<const AtomsCore::Metadata> getStaticMetadata(
const unsigned int jointId,
const std::string &metadataName)
const;
280 inline const std::map<std::string, AtomsPtr<AtomsCore::BaseTypedArrayMetadata>>& metadata(
const unsigned int jointId)
const;
282 inline const std::vector<std::string>& animatedMetadata(
const unsigned int jointId)
const;
284 inline unsigned int mapTimeToFrame(
const double time,
double &reminder,
unsigned int &nextFrame,
int offset = 0)
const;
285 inline unsigned int mapFrameToFrame(
const unsigned frame,
unsigned int &nextFrame)
const;
288 inline unsigned int numFrames()
const;
290 double getFactorFromFrame(
unsigned int frame,
unsigned int nextFrame,
double reminder,
unsigned int &loopedFrame,
unsigned int &loopedNextFrame)
const;
298 unsigned int m_numBlendFrames;
301 unsigned int m_loopStart;
304 unsigned int m_loopEnd;
309 #include "AnimationClipLooper.impl.h"
Animation clip looper.
Definition: AnimationClipLooper.h:27
AtomsCore::Quaternion getRotationAtGlobalFrame(const unsigned int jointId, const unsigned frame, const double reminder) const
Gets joint rotation at frame.
void setAnimationClip(AnimationClipCPtr animationClip)
Sets the animation clips.
AnimationClipLooper(AnimationClipCPtr animationClip)
Constructor.
void getTransformValuesAtFrame(const unsigned int jointId, const unsigned frame, const double reminder, AtomsCore::Vector3 &translation, AtomsCore::Quaternion &rotation, AtomsCore::Vector3 &scale) const
Gets joint transform at frame.
~AnimationClipLooper()
Destructor.
Definition: AnimationClipLooper.h:40
bool getMetadataInPlace(const unsigned int jointId, const std::string &metadataName, const double time, AtomsPtr< AtomsCore::Metadata > &outMeta, const int offset=0) const
Gets joint metadata value at time.
AtomsPtr< AtomsCore::Metadata > getMetadata(const unsigned int jointId, const std::string &metadataName, const double time, const int offset=0) const
Gets joint metadata value at time.
AtomsCore::Quaternion getRotationAtFrame(const unsigned int jointId, const unsigned frame, const double reminder) const
Gets joint rotation at frame.
AtomsCore::Vector3 getScaleAtGlobalFrame(const unsigned int jointId, const unsigned frame, const double reminder) const
Gets joint scale at frame.
void getMetadataAtFrameInPlace(const unsigned int jointId, const std::string &metadataName, const unsigned frame, const double reminder, AtomsPtr< AtomsCore::Metadata > &OutMeta) const
Gets joint metadata value at frame.
AtomsCore::Vector3 getTranslationAtGlobalFrame(const unsigned int jointId, const unsigned frame, const double reminder) const
Gets joint translation at frame.
AtomsCore::Vector3 getTranslationAtFrame(const unsigned int jointId, const unsigned frame, const double reminder) const
Gets joint translation at frame.
AtomsCore::Vector3 getTranslation(const unsigned int jointId, const double time, const int offset=0) const
Gets the joint translation.
AtomsCore::Vector3 getScaleAtFrame(const unsigned int jointId, const unsigned frame, const double reminder) const
Gets joint scale at frame.
void getTransformValues(const unsigned int jointId, const double time, AtomsCore::Vector3 &translation, AtomsCore::Quaternion &rotation, AtomsCore::Vector3 &scale, const int offset=0) const
Gets joint transform.
AtomsCore::Quaternion getRotation(const unsigned int jointId, const double time, const int offset=0) const
Gets joint rotation.
AtomsPtr< AtomsCore::Metadata > getMetadataAtFrame(const unsigned int jointId, const std::string &metadataName, const unsigned frame, const double reminder) const
Gets joint metadata value at frame.
AtomsCore::Vector3 getScale(const unsigned int jointId, const double time, const int offset=0) const
Gets joint scale.
AnimationClipLooper()
Constructor.
AtomsMath::Quaternion Quaternion
Quaternion class.
Definition: AtomsMath.h:67
AtomsMath::Vector3 Vector3
Vector3 class.
Definition: AtomsMath.h:57
Atoms namespace.
Definition: Agent.h:29
AnimationClipLooper * AnimationClipLooperPtr
animation clip looper pointer
Definition: AnimationClipLooper.h:17
const AnimationClipLooper * AnimationClipLooperCPtr
animation clip looper const pointer
Definition: AnimationClipLooper.h:21
AtomsPtr< const AnimationClip > AnimationClipCPtr
animation clip const pointer
Definition: AnimationClip.h:32