![]() |
ProtoTracer
1.0
Real-time 3D rendering and animation engine
|
A template class for managing 3D transformations using morph targets. More...
#include <MorphTransform.h>
Public Member Functions | |
MorphTransform (IEasyEaseAnimator *eEA) | |
Constructs a MorphTransform object with an animation controller. | |
void | AddMorph (uint16_t dictionaryValue, Vector3D positionOffset) |
Adds a morph target with a position offset. | |
void | AddMorph (uint16_t dictionaryValue, Vector3D positionOffset, Vector3D scaleOffset) |
Adds a morph target with position and scale offsets. | |
void | AddMorph (uint16_t dictionaryValue, Vector3D positionOffset, Vector3D scaleOffset, Vector3D rotationOffset) |
Adds a morph target with position, scale, and rotation offsets. | |
void | SetMorphPositionOffset (uint16_t dictionaryValue, Vector3D positionOffset) |
Sets the position offset for a specific morph target. | |
void | SetMorphScaleOffset (uint16_t dictionaryValue, Vector3D scaleOffset) |
Sets the scale offset for a specific morph target. | |
void | SetMorphRotationOffset (uint16_t dictionaryValue, Vector3D rotationOffset) |
Sets the rotation offset for a specific morph target. | |
Vector3D | GetPositionOffset () |
Retrieves the combined position offset for all active morph targets. | |
Vector3D | GetScaleOffset () |
Retrieves the combined scale offset for all active morph targets. | |
Vector3D | GetRotationOffset () |
Retrieves the combined rotation offset for all active morph targets. | |
Private Attributes | |
IEasyEaseAnimator * | eEA |
Pointer to the animation controller. | |
uint16_t | dictionary [maxMorphs] |
Dictionary mapping morph targets to identifiers. | |
uint16_t | currentMorphs = 0 |
Current number of morph targets. | |
Vector3D | positionOffsets [maxMorphs] |
Array of position offsets for morph targets. | |
Vector3D | scaleOffsets [maxMorphs] |
Array of scale offsets for morph targets. | |
Vector3D | rotationOffsets [maxMorphs] |
Array of rotation offsets for morph targets. | |
A template class for managing 3D transformations using morph targets.
The MorphTransform class allows the definition of multiple morph targets with position, scale, and rotation offsets. It integrates with an animation controller to dynamically calculate the resulting transformation based on animation values.
maxMorphs | The maximum number of morph targets this class can handle. |
Definition at line 29 of file MorphTransform.h.
MorphTransform | ( | IEasyEaseAnimator * | eEA | ) |
Constructs a MorphTransform object with an animation controller.
eEA | Pointer to the IEasyEaseAnimator instance. |
Adds a morph target with a position offset.
dictionaryValue | The identifier for the morph target. |
positionOffset | The position offset for the morph target. |
Referenced by DrGonzoProject::LinkControlParameters().
void AddMorph | ( | uint16_t | dictionaryValue, |
Vector3D | positionOffset, | ||
Vector3D | scaleOffset | ||
) |
Adds a morph target with position and scale offsets.
dictionaryValue | The identifier for the morph target. |
positionOffset | The position offset for the morph target. |
scaleOffset | The scale offset for the morph target. |
void AddMorph | ( | uint16_t | dictionaryValue, |
Vector3D | positionOffset, | ||
Vector3D | scaleOffset, | ||
Vector3D | rotationOffset | ||
) |
Adds a morph target with position, scale, and rotation offsets.
dictionaryValue | The identifier for the morph target. |
positionOffset | The position offset for the morph target. |
scaleOffset | The scale offset for the morph target. |
rotationOffset | The rotation offset for the morph target. |
Retrieves the combined position offset for all active morph targets.
Referenced by DrGonzoProject::Update().
Retrieves the combined rotation offset for all active morph targets.
Referenced by DrGonzoProject::Update().
Retrieves the combined scale offset for all active morph targets.
Referenced by DrGonzoProject::Update().
void SetMorphPositionOffset | ( | uint16_t | dictionaryValue, |
Vector3D | positionOffset | ||
) |
Sets the position offset for a specific morph target.
dictionaryValue | The identifier for the morph target. |
positionOffset | The new position offset. |
Referenced by DrGonzoProject::Update().
void SetMorphRotationOffset | ( | uint16_t | dictionaryValue, |
Vector3D | rotationOffset | ||
) |
Sets the rotation offset for a specific morph target.
dictionaryValue | The identifier for the morph target. |
rotationOffset | The new rotation offset. |
void SetMorphScaleOffset | ( | uint16_t | dictionaryValue, |
Vector3D | scaleOffset | ||
) |
Sets the scale offset for a specific morph target.
dictionaryValue | The identifier for the morph target. |
scaleOffset | The new scale offset. |
Current number of morph targets.
Definition at line 33 of file MorphTransform.h.
Dictionary mapping morph targets to identifiers.
Definition at line 32 of file MorphTransform.h.
|
private |
Pointer to the animation controller.
Definition at line 31 of file MorphTransform.h.
Array of position offsets for morph targets.
Definition at line 34 of file MorphTransform.h.
Array of rotation offsets for morph targets.
Definition at line 36 of file MorphTransform.h.
Array of scale offsets for morph targets.
Definition at line 35 of file MorphTransform.h.