aninest root / Animatable
Animatable
This module deals with creating and modifying Animations.
Index
Construction
Function | Description |
---|---|
createAnimation | Creates an animation info object, automatically inferring type from the init object. |
createParentAnimation | Creates a parent animation from a dictionary of children which will function the same as though the parent and children were created at once. |
Interpolation
Function | Description |
---|---|
changeInterpFunction | Changes the interpolation function of specific subproperties based on the mask. |
changeLocalInterpFunction | Updates the interpolation function of the animation only for the topmost level. |
State Modification
Function | Description |
---|---|
modifyTo | Sets the final stopping point of the animation. The animation will start to interpolate to the new state the next time updateAnimation is called. |
updateAnimation | Moves the animation forward by a certain amount of time. |
State Retrieval
Function | Description |
---|---|
getInterpingToTree | Gets the full state tree that the animation is currently interpolating to. If the animation is not headed to any state, it will return the current state. |
getLocalInterpingTo | Gets the local target state that the animation is currently headed to. If the animation is not headed to any state, it will return the current state. This only returns the local state of the animation, meaning only the numbers in the topmost level of the animation. |
getLocalInterpingToValue | Gets a value |
getLocalState | Gets the current local state of the animation, meaning only the strings and numbers in the topmost level of the animation. To access the local state of a child, use anim.children.childName as the input. Numbers will smoothly interpolate from the starting to the ending value while strings will snap to the ending value once the animation is at least 50% complete. |
getStateTree | Gets the full state of the animation, including all children. |
Status
Function | Description |
---|---|
animationNeedsUpdate | Returns whether the animation needs to be updated. |