Castor3D 0.16.0
Multiplatform 3D engine
|
#include <AnimatedSkeleton.hpp>
Public Member Functions | |
C3D_API | AnimatedSkeleton (castor::String const &name, Skeleton &skeleton, Mesh &mesh, Geometry &geometry) |
Constructor. | |
C3D_API uint32_t | fillBuffer (SkinningTransformsConfiguration *buffer) const |
Fills a buffer with this object's skeleton transforms. | |
C3D_API void | update (castor::Milliseconds const &elapsed) override |
Updates the animations of the object, given the time since the last frame. | |
bool | isPlayingAnimation () const override |
Skeleton & | getSkeleton () const |
Mesh & | getMesh () const |
Geometry & | getGeometry () const |
uint32_t | getId () const |
void | setId (uint32_t id) |
C3D_API | AnimatedSkeleton (AnimatedSkeleton &&rhs) noexcept=default |
C3D_API AnimatedSkeleton & | operator= (AnimatedSkeleton &&rhs) noexcept=delete |
C3D_API | AnimatedSkeleton (AnimatedSkeleton const &rhs)=delete |
C3D_API AnimatedSkeleton & | operator= (AnimatedSkeleton const &rhs)=delete |
C3D_API | ~AnimatedSkeleton () noexcept override=default |
Public Member Functions inherited from castor3d::AnimatedObject | |
C3D_API | AnimatedObject (AnimationType kind, castor::String const &name) |
Constructor. | |
virtual C3D_API | ~AnimatedObject () noexcept=default |
Destructor. | |
C3D_API void | addAnimation (castor::String const &name) |
adds the animation to the list | |
C3D_API void | startAnimation (castor::String const &name) |
Starts the animation identified by the given name. | |
C3D_API void | stopAnimation (castor::String const &name) |
Stops the animation identified by the given name. | |
C3D_API void | pauseAnimation (castor::String const &name) |
Pauses the animation identified by the given name. | |
C3D_API void | startAllAnimations () |
Starts all animations. | |
C3D_API void | stopAllAnimations () |
Stops all animations. | |
C3D_API void | pauseAllAnimations () |
Pauses all animations. | |
C3D_API AnimationInstance & | getAnimation (castor::String const &name) |
Retrieves an animation. | |
C3D_API | AnimatedObject (AnimatedObject &&rhs) noexcept=default |
C3D_API AnimatedObject & | operator= (AnimatedObject &&rhs) noexcept=default |
C3D_API | AnimatedObject (AnimatedObject const &rhs)=delete |
C3D_API AnimatedObject & | operator= (AnimatedObject const &rhs)=delete |
bool | hasAnimation (castor::String const &name) |
AnimationInstancesMap const & | getAnimations () const |
AnimationType | getKind () const |
Public Member Functions inherited from castor::NamedBaseT< T > | |
NamedBaseT (T name) noexcept | |
Constructor. | |
T const & | getName () const noexcept |
Retrieves the name. | |
void | rename (T name) noexcept |
Protected Types | |
using | InstanceArray = castor::Vector< SkeletonAnimationInstance * > |
Protected Attributes | |
Skeleton & | m_skeleton |
Mesh & | m_mesh |
Geometry & | m_geometry |
InstanceArray | m_playingAnimations |
uint32_t | m_id {} |
bool | m_reinit = true |
Protected Attributes inherited from castor3d::AnimatedObject | |
AnimationInstancesMap | m_animations |
Protected Attributes inherited from castor::NamedBaseT< T > | |
T | m_name |
Additional Inherited Members | |
Public Types inherited from castor3d::AnimatedObject | |
using | AnimationInstancesMap = castor::StringMap< AnimationInstanceUPtr > |
|
protected |
|
defaultnoexcept |
name Copy / Move.
|
delete |
|
overridedefaultnoexcept |
C3D_API castor3d::AnimatedSkeleton::AnimatedSkeleton | ( | castor::String const & | name, |
Skeleton & | skeleton, | ||
Mesh & | mesh, | ||
Geometry & | geometry ) |
Constructor.
[in] | name | The object name. |
[in] | skeleton | The skeleton. |
[in] | mesh | The mesh to which the skeleton is bound. |
[in] | geometry | The geometry instantiating the mesh. |
C3D_API uint32_t castor3d::AnimatedSkeleton::fillBuffer | ( | SkinningTransformsConfiguration * | buffer | ) | const |
Fills a buffer with this object's skeleton transforms.
[out] | buffer | Receives the transforms. |
|
inline |
References m_geometry.
|
inline |
References m_id.
|
inline |
References m_skeleton.
|
inlineoverridevirtual |
true
if the object is playing an animation. Implements castor3d::AnimatedObject.
References m_playingAnimations.
|
deletenoexcept |
|
delete |
|
inline |
References m_id.
|
overridevirtual |
Updates the animations of the object, given the time since the last frame.
[in] | elapsed | Time elapsed since the last frame |
Implements castor3d::AnimatedObject.
|
protected |
Referenced by getGeometry().
|
protected |
Referenced by isPlayingAnimation().
|
mutableprotected |
|
protected |
Referenced by getSkeleton().