Castor3D  ..
Public Member Functions | Friends | List of all members
Castor3D::Bone Class Reference

Class holding bone data. More...

Public Member Functions

C3D_API Bone (Skeleton &p_skeleton)
 Constructor. More...
 
C3D_API ~Bone ()
 Destructor. More...
 
template<typename FuncT >
void TraverseHierarchy (FuncT p_function)
 Traverses bone hierarchy and applies given function to each bone. More...
 
Castor::String const & GetName () const
 Retrieves the bone name. More...
 
void SetName (Castor::String const &p_name)
 Sets the bone name. More...
 
const Castor::Matrix4x4r & GetOffsetMatrix () const
 Retrieves the transfromation matrix from mesh space to bone space. More...
 
void SetOffsetMatrix (const Castor::Matrix4x4r &p_offset)
 Sets the transfromation matrix from mesh space to bone space. More...
 
const Castor::Matrix4x4r & GetFinalTransformation () const
 Retrieves final transformation matrix for current animation time. More...
 
void SetFinalTransformation (const Castor::Matrix4x4r &p_mtx)
 Sets final transformation for current animation time. More...
 
const SkeletonGetSkeleton () const
 Retrieves the parent skeleton. More...
 
BonePtrArray const & GetChildren () const
 
BoneSPtr GetParent () const
 

Friends

class Skeleton
 

Detailed Description

Class holding bone data.

Author
Sylvain DOREMUS
Date
26/06/2013
Version
0.7.0
Remarks
Holds weight for each vertice and matrix from mesh space to bone space

Constructor & Destructor Documentation

◆ Bone()

C3D_API Castor3D::Bone::Bone ( Skeleton p_skeleton)

Constructor.

Parameters
[in]p_skeletonThe parent skeleton

◆ ~Bone()

C3D_API Castor3D::Bone::~Bone ( )

Destructor.

Member Function Documentation

◆ GetChildren()

BonePtrArray const& Castor3D::Bone::GetChildren ( ) const
inline
Returns
The children array.

◆ GetFinalTransformation()

const Castor::Matrix4x4r& Castor3D::Bone::GetFinalTransformation ( ) const
inline

Retrieves final transformation matrix for current animation time.

Returns
The value

◆ GetName()

Castor::String const& Castor3D::Bone::GetName ( ) const
inline

Retrieves the bone name.

Returns
The value

◆ GetOffsetMatrix()

const Castor::Matrix4x4r& Castor3D::Bone::GetOffsetMatrix ( ) const
inline

Retrieves the transfromation matrix from mesh space to bone space.

Returns
The value

◆ GetParent()

BoneSPtr Castor3D::Bone::GetParent ( ) const
inline
Returns
The parent bone.

◆ GetSkeleton()

const Skeleton& Castor3D::Bone::GetSkeleton ( ) const
inline

Retrieves the parent skeleton.

Returns
The value

◆ SetFinalTransformation()

void Castor3D::Bone::SetFinalTransformation ( const Castor::Matrix4x4r &  p_mtx)
inline

Sets final transformation for current animation time.

Parameters
[in]p_mtxThe new value

◆ SetName()

void Castor3D::Bone::SetName ( Castor::String const &  p_name)
inline

Sets the bone name.

Parameters
[in]p_nameThe new value

◆ SetOffsetMatrix()

void Castor3D::Bone::SetOffsetMatrix ( const Castor::Matrix4x4r &  p_offset)
inline

Sets the transfromation matrix from mesh space to bone space.

Parameters
[in]p_offsetThe new value

◆ TraverseHierarchy()

template<typename FuncT >
void Castor3D::Bone::TraverseHierarchy ( FuncT  p_function)
inline

Traverses bone hierarchy and applies given function to each bone.

Parameters
[in]p_functionThe function to apply.

Friends And Related Function Documentation

◆ Skeleton

friend class Skeleton
friend

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