This reference page is linked to from the following overview topics: List of Python Fbx classes.
#include <fbxcluster.h>
Class for clusters (links).
A cluster, or link, is an entity acting on a geometry (FbxGeometry). More precisely, the cluster acts on a subset of the geometry's control points. For each control point that the cluster acts on, the intensity of the cluster's action is modulated by a weight. The link mode (ELinkMode) specifies how the weights are taken into account.
The cluster's link node specifies the node (FbxNode) that influences the control points of the cluster. If the node is animated, the control points will move accordingly.
A cluster is usually part of a skin (
ExportScene01/main.cxx, ImportScene/DisplayLink.cxx, SwitchBinding/main.cxx, and ViewScene/DrawScene.cxx.
Definition at line 47 of file fbxcluster.h.
Public Member Functions |
|
| void | SetControlPointIWCount (int pCount) |
| Set the array size for the three arrays: the
array of control point indices, the array of weights and the array
of blend weights. |
|
General Functions |
|
| EType | GetSubDeformerType () const |
| Get the type of the sub deformer. |
|
| void | Reset () |
| Restore the cluster to its initial state.
|
|
Link Mode, Link Node, Associate Model |
|
| enum | ELinkMode { eNormalize, eAdditive, eTotalOne } |
| Link modes. More... |
|
| void | SetLinkMode (ELinkMode pMode) |
| Set the link mode. |
|
| ELinkMode | GetLinkMode () const |
| Get the link mode. |
|
| void | SetLink (const FbxNode *pNode) |
| Set the link node. |
|
| FbxNode * | GetLink () |
| Get the link node. |
|
| const FbxNode * | GetLink () const |
| Get the link node (as const). |
|
| void | SetAssociateModel (FbxNode *pNode) |
| Set the associate model. |
|
| FbxNode * | GetAssociateModel () const |
| Get the associate model. |
|
Control Points |
|
|
A link has an array of indices to control points and associated weights. The indices refer to the control points in the instance of class FbxGeometry owning the link. The weights are the influence of the link node over the displacement of the indexed control points. |
|
| void | AddControlPointIndex (int pIndex, double pWeight) |
| Add an element in both arrays of control
point indices and weights. |
|
| int | GetControlPointIndicesCount () const |
| Get the length of the arrays of control
point indices and weights. |
|
| int * | GetControlPointIndices () const |
| Get the array of control point indices.
|
|
| double * | GetControlPointWeights () const |
| Get the array of control point weights.
|
|
Transformation matrices |
|
|
A link has three transformation matrices:
For example, given a mesh binding with several bones(links), Transform is the global transform of the mesh at the binding moment, TransformLink is the global transform of the bone(link) at the binding moment, TransformAssociateModel is the global transform of the associate model at the binding moment. |
|
| void | SetTransformMatrix (const FbxAMatrix &pMatrix) |
| Set matrix associated with the node
containing the link. |
|
| FbxAMatrix & | GetTransformMatrix (FbxAMatrix &pMatrix) const |
| Get matrix associated with the node
containing the link. |
|
| void | SetTransformLinkMatrix (const FbxAMatrix &pMatrix) |
| Set matrix associated with the link node.
|
|
| FbxAMatrix & | GetTransformLinkMatrix (FbxAMatrix &pMatrix) const |
| Get matrix associated with the link node.
|
|
| void | SetTransformAssociateModelMatrix (const FbxAMatrix &pMatrix) |
| Set matrix associated with the associate
model. |
|
| FbxAMatrix & | GetTransformAssociateModelMatrix (FbxAMatrix &pMatrix) const |
| Get matrix associated with the associate
model. |
|
| void | SetTransformParentMatrix (const FbxAMatrix &pMatrix) |
| Set matrix associated with the parent node.
|
|
| FbxAMatrix & | GetTransformParentMatrix (FbxAMatrix &pMatrix) const |
| Get matrix associated with the parent node.
|
|
| bool | IsTransformParentSet () const |
| Get the Transform Parent set flag value.
|
|
| enum ELinkMode |
Link modes.
The link mode sets how the link influences the position of a control point and the relationship between the weights assigned to a control point. The weights assigned to a control point are distributed among the set of links associated with an instance of class FbxGeometry.
Definition at line 80 of file fbxcluster.h.
{
eNormalize,
eAdditive,
eTotalOne
};
| EType GetSubDeformerType | ( | ) | const [inline, virtual] |
Get the type of the sub deformer.
Reimplemented from FbxSubDeformer.
Definition at line 59 of file fbxcluster.h.
{return eCluster; };
| void Reset | ( | ) |
Restore the cluster to its initial state.
Calling this function will clear the following:
| void SetLinkMode | ( | ELinkMode | pMode | ) |
Set the link mode.
| pMode | The link mode. |
| ELinkMode GetLinkMode | ( | ) | const |
Get the link mode.
| void SetLink | ( | const FbxNode * | pNode | ) |
Set the link node.
The link node is the node which influences the displacement of the control points. Typically, the link node is the bone a skin is attached to.
| pNode | The link node. |
| FbxNode* GetLink | ( | ) |
Get the link node.
The link node is the node which influences the displacement of the control points. Typically, the link node is the bone a skin is attached to.
NULL if FbxCluster::SetLink() has not been called
before.| const FbxNode* GetLink | ( | ) | const |
Get the link node (as const).
The link node is the node which influences the displacement of the control points. Typically, the link node is the bone a skin is attached to.
NULL if FbxCluster::SetLink() has not been called
before.| void SetAssociateModel | ( | FbxNode * | pNode | ) |
Set the associate model.
The associate model is optional. It is only relevant if the link mode is of type eAdditive. If set, the associate model is the node used as a reference to measure the relative displacement of the link node. Otherwise, the displacement of the link node is measured relative to the node containing the control points. Typically, the associate model node is the parent of the bone a skin is attached to.
| pNode | The associate model node. |
| FbxNode* GetAssociateModel | ( | ) | const |
Get the associate model.
The associate model is optional. It is only relevant if the link mode is of type eAdditive. If set, the associate model is the node used as a reference to measure the relative displacement of the link node. Otherwise, the displacement of the link node is measured relative the the node containing the control points. Typically, the associate model node is the parent of the bone a skin is attached to.
NULL if FbxCluster::SetAssociateModel() has
not been called before.| void AddControlPointIndex | ( | int | pIndex, |
| double | pWeight | ||
| ) |
Add an element in both arrays of control point indices and weights.
| pIndex | The index of the control point. |
| pWeight | The link weight for this control point. |
| int GetControlPointIndicesCount | ( | ) | const |
Get the length of the arrays of control point indices and weights.
| int* GetControlPointIndices | ( | ) | const |
Get the array of control point indices.
NULL if no control point indices have been added or
the array has been reset.| double* GetControlPointWeights | ( | ) | const |
Get the array of control point weights.
NULL if no control point indices have been added or
the array has been reset.| void SetControlPointIWCount | ( | int | pCount | ) |
Set the array size for the three arrays: the array of control point indices, the array of weights and the array of blend weights.
| pCount | The new count. |
| void SetTransformMatrix | ( | const FbxAMatrix & | pMatrix | ) |
Set matrix associated with the node containing the link.
| pMatrix | Transformation matrix. |
| FbxAMatrix& GetTransformMatrix | ( | FbxAMatrix & | pMatrix | ) | const |
Get matrix associated with the node containing the link.
| pMatrix | Transformation matrix to be filled with appropriate data. |
| void SetTransformLinkMatrix | ( | const FbxAMatrix & | pMatrix | ) |
Set matrix associated with the link node.
| pMatrix | Transformation matrix. |
| FbxAMatrix& GetTransformLinkMatrix | ( | FbxAMatrix & | pMatrix | ) | const |
Get matrix associated with the link node.
| pMatrix | Transformation matrix to be filled with appropriate data.. |
| void SetTransformAssociateModelMatrix | ( | const FbxAMatrix & | pMatrix | ) |
Set matrix associated with the associate model.
| pMatrix | Transformation matrix. |
| FbxAMatrix& GetTransformAssociateModelMatrix | ( | FbxAMatrix & | pMatrix | ) | const |
Get matrix associated with the associate model.
| pMatrix | Transformation matrix to be filled with appropriate data.. |
| void SetTransformParentMatrix | ( | const FbxAMatrix & | pMatrix | ) |
Set matrix associated with the parent node.
| pMatrix | Transformation matrix. |
| FbxAMatrix& GetTransformParentMatrix | ( | FbxAMatrix & | pMatrix | ) | const |
Get matrix associated with the parent node.
| pMatrix | Transformation matrix to be filled with appropriate data.. |
| bool IsTransformParentSet | ( | ) | const [inline] |
Get the Transform Parent set flag value.
true if transform matrix associated with parent
node is set.Definition at line 253 of file fbxcluster.h.
{ return mIsTransformParentSet; }