| - Cal3D 0.11 API Reference - |
Public Member Functions | |
| CalMorphTargetMixer (CalModel *model) | |
| Constructs the morph target mixer instance. | |
| bool | blend (int id, float weight, float delay) |
| Interpolates the weight of a morph target. | |
| bool | clear (int id, float delay) |
| Fades a morph target out. | |
| float | getCurrentWeight (int id) |
| Get the weight of a morph target. | |
| float | getCurrentWeightBase () |
| Get the weight of the base vertices. | |
| int | getMorphTargetCount () |
| Returns the number of morph targets this morph target mixer mixes. | |
| void | update (float deltaTime) |
| Updates all morph targets. | |
| CalMorphTargetMixer::CalMorphTargetMixer | ( | CalModel * | pModel | ) |
Constructs the morph target mixer instance.
This function is the default constructor of the morph target mixer instance.
| bool CalMorphTargetMixer::blend | ( | int | id, |
| float | weight, | ||
| float | delay | ||
| ) |
Interpolates the weight of a morph target.
This function interpolates the weight of a morph target a new value in a given amount of time.
| id | The ID of the morph target that should be blended. |
| weight | The weight to interpolate the morph target to. |
| delay | The time in seconds until the new weight should be reached. |
| bool CalMorphTargetMixer::clear | ( | int | id, |
| float | delay | ||
| ) |
Fades a morph target out.
This function fades a morph target out in a given amount of time.
| id | The ID of the morph target that should be faded out. |
| delay | The time in seconds until the the morph target is completely removed. |
| float CalMorphTargetMixer::getCurrentWeight | ( | int | id | ) |
Get the weight of a morph target.
| id | The id of the morph target which weight you want. |
Get the weight of the base vertices.
Returns the number of morph targets this morph target mixer mixes.
| void CalMorphTargetMixer::update | ( | float | deltaTime | ) |
Updates all morph targets.
This function updates all morph targets of the mixer instance for a given amount of time.
| deltaTime | The elapsed time in seconds since the last update. |