Inherits EMotionFX::BaseObject.
◆ AddRootNode()
void EMotionFX::Skeleton::AddRootNode |
( |
size_t |
nodeIndex | ) |
|
Add a root node to the actor. This doesn't modify the node itself, but it will add the node to the list of root nodes.
- Parameters
-
nodeIndex | The node number/index to add and mark as root node inside the actor. |
◆ FindNodeAndIndexByName()
Node * EMotionFX::Skeleton::FindNodeAndIndexByName |
( |
const AZStd::string & |
name, |
|
|
size_t & |
outIndex |
|
) |
| const |
Find a joint's index and pointer by name.
- Parameters
-
name | The name of the joint, non case sensitive. |
outIndex | This will contain the resulting index, or MCORE_INVALIDINDEX32 in case not found. |
- Returns
- This returns a pointer to the joint or nullptr when not found. In case of a nullptr, the outIndex will be set to MCORE_INVALIDINDEX32 as well.
◆ FindNodeByID()
Node * EMotionFX::Skeleton::FindNodeByID |
( |
size_t |
id | ) |
const |
Search for a node on ID. Returns nullptr when no node found. A node ID is based on the name. So all nodes (also inside other actors) with the same name will have the same ID. This can be used for faster searching, compared to searching by name, which uses string compares.
- Parameters
-
- Returns
- A pointer to the node, or nullptr when no node with the given ID found.
◆ FindNodeByName()
Node * EMotionFX::Skeleton::FindNodeByName |
( |
const char * |
name | ) |
const |
Search for a node by name (case sensitive).
- Parameters
-
name | The name of the node (case sensitive). |
- Returns
- A pointer to the node, returns nullptr when not found.
◆ FindNodeByNameNoCase()
Node * EMotionFX::Skeleton::FindNodeByNameNoCase |
( |
const char * |
name | ) |
const |
Search for a node by name (non case sensitive), returns nullptr when no node can be found. Note: when there are two nodes with the same non case sensitive name, the first one is returned. So if there is a node named "Blah" and one named "BLAH" and we search on "blah", the first one ("Blah") is returned.
- Parameters
-
name | The name of the node, non case sensitive. |
- Returns
- A pointer to the node with the given name, or nullptr when none could be found.
◆ GetNumRootNodes()
MCORE_INLINE size_t EMotionFX::Skeleton::GetNumRootNodes |
( |
| ) |
const |
|
inline |
Get the number of root nodes in the actor. A root node is a node without any parent.
- Returns
- The number of root nodes inside the actor.
◆ GetRootNodeIndex()
MCORE_INLINE size_t EMotionFX::Skeleton::GetRootNodeIndex |
( |
size_t |
nr | ) |
const |
|
inline |
Get the node number/index of a given root node.
- Parameters
-
- Returns
- The node index of the given root node.
◆ RemoveAllRootNodes()
void EMotionFX::Skeleton::RemoveAllRootNodes |
( |
| ) |
|
Removes all root nodes from the actor. This doesn't remove the actual nodes, but it just unregisters them as root nodes, so that the GetNumRootNodes() method will return a value of zero.
◆ RemoveRootNode()
void EMotionFX::Skeleton::RemoveRootNode |
( |
size_t |
nr | ) |
|
Remove a given root node from the list of root nodes stored inside the actor. This doesn't really remove the node itself, but it just unregisters it as root node inside the actor.
- Parameters
-
◆ ReserveRootNodes()
void EMotionFX::Skeleton::ReserveRootNodes |
( |
size_t |
numNodes | ) |
|
Pre-allocate space for the root nodes array. This does not alter the value returned by GetNumRootNodes() though.
- Parameters
-
numNodes | The absolute number of nodes to pre-allocate space for. |
◆ SetNode()
void EMotionFX::Skeleton::SetNode |
( |
size_t |
index, |
|
|
Node * |
node |
|
) |
| |
Set the value of a given node.
- Parameters
-
index | The node number, which must be in range of [0..GetNumNodes()-1]. |
node | The node value to set at this index. |
◆ SetNumNodes()
void EMotionFX::Skeleton::SetNumNodes |
( |
size_t |
numNodes | ) |
|
Set the number of nodes. This resizes the array of pointers to nodes, but doesn't actually create the nodes.
- Parameters
-
numNodes | The number of nodes to allocate space for. |
◆ UpdateNodeIndexValues()
void EMotionFX::Skeleton::UpdateNodeIndexValues |
( |
size_t |
startNode = 0 | ) |
|
Update all the node index values that are returned by the Node::GetNodeIndex() method. When the order or layout of the nodes array changes, for example after removing a node, the index values of the nodes have to be updated. As node number 5 could become node number 4 in the example case.
- Parameters
-
startNode | The node number to start updating from. |
The documentation for this class was generated from the following file:
- Gems/EMotionFX/Code/EMotionFX/Source/Skeleton.h