Open 3D Engine EMotionFX Gem API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
EMotionFX::KeyFrame< ReturnType, StorageType > Class Template Reference

#include <KeyFrame.h>

Public Member Functions

 AZ_TYPE_INFO_WITH_NAME (KeyFrame, "EMotionFX::KeyFrame", "{BCB35EA0-4C4C-4482-B32A-5E1D1F461D3D}", StorageType)
 
 KeyFrame ()
 
 KeyFrame (float time, const ReturnType &value)
 
 ~KeyFrame ()
 
MCORE_INLINE float GetTime () const
 
MCORE_INLINE ReturnType GetValue () const
 
MCORE_INLINE const StorageType & GetStorageTypeValue () const
 
MCORE_INLINE void GetValue (ReturnType *outValue)
 
MCORE_INLINE void GetStorageTypeValue (StorageType *outValue)
 
MCORE_INLINE void SetTime (float time)
 
MCORE_INLINE void SetValue (const ReturnType &value)
 
MCORE_INLINE void SetStorageTypeValue (const StorageType &value)
 
MCORE_INLINE void SetValue (const AZ::Quaternion &value)
 
MCORE_INLINE AZ::Quaternion GetValue () const
 
MCORE_INLINE void GetValue (AZ::Quaternion *outValue)
 
MCORE_INLINE void SetStorageTypeValue (const MCore::Compressed8BitQuaternion &value)
 
MCORE_INLINE const MCore::Compressed8BitQuaternionGetStorageTypeValue () const
 
MCORE_INLINE void SetValue (const AZ::Quaternion &value)
 
MCORE_INLINE AZ::Quaternion GetValue () const
 
MCORE_INLINE void GetValue (AZ::Quaternion *outValue)
 
MCORE_INLINE void SetStorageTypeValue (const MCore::Compressed16BitQuaternion &value)
 
MCORE_INLINE const MCore::Compressed16BitQuaternionGetStorageTypeValue () const
 
MCORE_INLINE void SetValue (const float &value)
 
MCORE_INLINE float GetValue () const
 
MCORE_INLINE void GetValue (float *outValue)
 
MCORE_INLINE void SetStorageTypeValue (const MCore::Compressed8BitFloat &value)
 
MCORE_INLINE const MCore::Compressed8BitFloatGetStorageTypeValue () const
 
MCORE_INLINE void SetValue (const float &value)
 
MCORE_INLINE float GetValue () const
 
MCORE_INLINE void GetValue (float *outValue)
 
MCORE_INLINE void SetStorageTypeValue (const MCore::Compressed16BitFloat &value)
 
MCORE_INLINE const MCore::Compressed16BitFloatGetStorageTypeValue () const
 

Static Public Member Functions

static void Reflect (AZ::ReflectContext *context)
 

Protected Attributes

StorageType m_value
 
float m_time
 

Detailed Description

template<class ReturnType, class StorageType = ReturnType>
class EMotionFX::KeyFrame< ReturnType, StorageType >

The keyframe class. Each keyframe holds a value at a given time. Interpolators can then calculate interpolated values between a set of keys, which are stored inside a key track. This makes it possible to do keyframed animations.

Constructor & Destructor Documentation

◆ KeyFrame() [1/2]

template<class ReturnType , class StorageType >
EMotionFX::KeyFrame< ReturnType, StorageType >::KeyFrame

Default constructor.

◆ KeyFrame() [2/2]

template<class ReturnType , class StorageType >
EMotionFX::KeyFrame< ReturnType, StorageType >::KeyFrame ( float  time,
const ReturnType &  value 
)

Constructor which sets the time and value.

Parameters
timeThe time of the keyframe, in seconds.
valueThe value at this time.

◆ ~KeyFrame()

template<class ReturnType , class StorageType >
EMotionFX::KeyFrame< ReturnType, StorageType >::~KeyFrame

Destructor.

Member Function Documentation

◆ GetStorageTypeValue() [1/2]

template<class ReturnType , class StorageType >
MCORE_INLINE const StorageType & EMotionFX::KeyFrame< ReturnType, StorageType >::GetStorageTypeValue

Return the storage type value of the keyframe.

Returns
The storage type value of the keyframe.

◆ GetStorageTypeValue() [2/2]

template<class ReturnType , class StorageType = ReturnType>
MCORE_INLINE void EMotionFX::KeyFrame< ReturnType, StorageType >::GetStorageTypeValue ( StorageType *  outValue)

Get the storage type value of the keyframe.

Parameters
outValueThe storage type value of the keyframe.

◆ GetTime()

template<class ReturnType , class StorageType >
MCORE_INLINE float EMotionFX::KeyFrame< ReturnType, StorageType >::GetTime

Return the time of the keyframe.

Returns
The time, in seconds.

◆ GetValue() [1/2]

template<class ReturnType , class StorageType >
MCORE_INLINE ReturnType EMotionFX::KeyFrame< ReturnType, StorageType >::GetValue

Return the value of the keyframe.

Returns
The value of the keyframe.

◆ GetValue() [2/2]

template<class ReturnType , class StorageType >
MCORE_INLINE void EMotionFX::KeyFrame< ReturnType, StorageType >::GetValue ( ReturnType *  outValue)

Get the value of the keyframe.

Parameters
outValueThe value of the keyframe.

◆ SetStorageTypeValue()

template<class ReturnType , class StorageType >
MCORE_INLINE void EMotionFX::KeyFrame< ReturnType, StorageType >::SetStorageTypeValue ( const StorageType &  value)

Set the storage type value.

Parameters
valueThe storage type value.

◆ SetTime()

template<class ReturnType , class StorageType >
MCORE_INLINE void EMotionFX::KeyFrame< ReturnType, StorageType >::SetTime ( float  time)

Set the time of the keyframe.

Parameters
timeThe time of the keyframe, in seconds.

◆ SetValue()

template<class ReturnType , class StorageType >
MCORE_INLINE void EMotionFX::KeyFrame< ReturnType, StorageType >::SetValue ( const ReturnType &  value)

Set the value.

Parameters
valueThe value.

Member Data Documentation

◆ m_time

template<class ReturnType , class StorageType = ReturnType>
float EMotionFX::KeyFrame< ReturnType, StorageType >::m_time
protected

Time in seconds.

◆ m_value

template<class ReturnType , class StorageType = ReturnType>
StorageType EMotionFX::KeyFrame< ReturnType, StorageType >::m_value
protected

The key value.


The documentation for this class was generated from the following files: