Expand description
Easings made from a name, a function or a spring. Each is an Easing the evaluator
already knows, so no curve family adds arithmetic to it.
Structs§
- Spring
- A mass on a damped spring, released at rest position 0 toward 1.
- Spring
Easing - A spring’s motion as an easing, and how long it lasts.
Constants§
- EASING_
FAMILIES - The ten families of
named, each with anin, anoutand anin-outform. - MAX_
SPRING_ SECONDS - How long a spring may take to settle.
- PRESET_
POINTS - The most points a table made for a named easing has; the longest is
ease-in-out-bounce. - PRESET_
TOLERANCE - How close a table made for a named easing stays to its function.
Functions§
- easing_
equation - Penner’s easing equation for a family name of
named, such asease-out-bounce, atprogress(clamped to0..=1): what the name’s curve or table follows.Nonefor any other name. - easing_
names - Every name
namedknows, in a fixed order: the CSS names, the two step names, then each family’sease-in-,ease-out-andease-in-out-form. - named
- The easing a name stands for:
linear, the CSS names (ease,ease-in,ease-out,ease-in-out),step-start,step-end, andease-{in,out,in-out}-{sine,quad,cubic,quart,quint,expo,circ,back,elastic,bounce}. - sampled
function, which runs from 0 at 0 to 1 at 1, as apointseasing: straight lines withintoleranceof it at the quarter points of every piece, through at mostmax_pointspoints (and at mostMAX_EASING_POINTS).- spring
- A spring’s motion from 0 to 1 over the time it takes to stay within 0.001 of 1, as a table
within
toleranceof it of at mostmax_pointspoints (sampled).