Axmol 3.0.0-89d6d9a
Loading...
Searching...
No Matches
Bone3D Class Reference

Defines a basic hierarchical structure of transformation spaces. More...

#include <Skeleton3D.h>

Inherits Object.

Public Member Functions

const Mat4 & getInverseBindPose ()
 Returns the inverse bind pose matrix for this joint.
void updateWorldMat ()
 update own world matrix and children's
const Mat4 & getWorldMat ()
 get world matrix
std::string_view getName () const
 get bone name
void setAnimationValue (float *trans, float *rot, float *scale, void *tag=nullptr, float weight=1.0f)
 set animation value
void clearBoneBlendState ()
 clear bone blend states
void setInverseBindPose (const Mat4 &m)
 Sets the inverse bind pose matrix.
void setOriPose (const Mat4 &m)
 Sets the bone's original pose.
void resetPose ()
 reset pose to origin
void updateJointMatrix (Vec4 *matrixPalette)
 Updates the joint matrix.
Bone3D * getParentBone ()
 bone tree, we do not inherit from Node, Node has too many properties that we do not need.
ssize_t getChildBoneCount () const
 get child bone count
Bone3D * getChildBoneByIndex (int index) const
 get child bone by index
void addChildBone (Bone3D *bone)
 add child bone
void removeChildBoneByIndex (int index)
 remove child bone by index
void removeChildBone (Bone3D *bone)
 remove child bone
void removeAllChildBone ()
 remove all child bone
Public Member Functions inherited from Object
void retain ()
 Retains the ownership.
void release ()
 Releases the ownership immediately.
Object * autorelease ()
 Releases the ownership sometime soon automatically.
unsigned int getReferenceCount () const
 Returns the Object's current reference count.
uint64_t getObjectID () const noexcept
 Returns the process-local diagnostic identifier assigned at construction.
virtual ~Object ()
 Destructor.

Static Public Member Functions

static Bone3D * create (std::string_view id)
 Creates C3DBone.

Detailed Description

Defines a basic hierarchical structure of transformation spaces.

@lua NA

Member Function Documentation

◆ getInverseBindPose()

const Mat4 & getInverseBindPose ( )

Returns the inverse bind pose matrix for this joint.

Returns
Inverse bind pose matrix.

◆ setAnimationValue()

void setAnimationValue ( float * trans,
float * rot,
float * scale,
void * tag = nullptr,
float weight = 1.0f )

set animation value

Parameters
transtranslate vec3
rotrotation quaternion
scalescale vec3
tagunique tag, only blend animation between different tags
weightblend weight

◆ setInverseBindPose()

void setInverseBindPose ( const Mat4 & m)

Sets the inverse bind pose matrix.

Parameters
mMat4 representing the inverse bind pose for this Bone.

◆ setOriPose()

void setOriPose ( const Mat4 & m)

Sets the bone's original pose.

Parameters
mMat4 representing the original pose for this Bone.

◆ updateJointMatrix()

void updateJointMatrix ( Vec4 * matrixPalette)

Updates the joint matrix.

Parameters
matrixPaletteThe matrix palette to update.

◆ getParentBone()

Bone3D * getParentBone ( )

bone tree, we do not inherit from Node, Node has too many properties that we do not need.

A clean Node is needed.


The documentation for this class was generated from the following file:
  • Skeleton3D.h