Skip to content

Easings

Optional easings that can be applied to change the rate at which values set by triggers change over time.

Formulas

Ease

EaseIn(x, easeRate)={0forx0x0.01(1easeRate)for0<x0.01xeaseRatefor0.01<x<11forx1EaseOut(x, easeRate)={0forx0xeaseRate1for0<x<11forx1EaseInOut(x, easeRate)={EaseIn(2x, easeRate)/2x<0.51EaseIn(22x, easeRate)/2x0.5

Elastic

ElasticIn(x, easeRate)={0forx0ExponentialIn(x)sin(π(0.5+22xeaseRate))for0<x<11forx1ElasticOut(x, easeRate)=1ElasticIn(1x, easeRate)ElasticInOut(x, easeRate)={ElasticIn(2x, easeRate)/2x<0.51ElasticIn(22x, easeRate)/2x0.5

Bounce

BounceIn(x)=1BounceOut(1x)BounceOut(x)={0forx07.5625x2for0<x<2.7517.5625(x1.52.75)2+0.75for2.751x<22.757.5625(x2.252.75)2+0.9375for22.75x<2.52.757.5625(x2.6252.75)2+0.984375for2.52.75x<11forx1BounceInOut(x)={BounceIn(2x)/2x<0.51BounceIn(22x)/2x0.5

Exponential

ExponentialIn(x)={0forx0210(x1)for0<x<11forx1ExponentialOut(x)=1ExponentialIn(1x)ExponentialInOut(x)={ExponentialIn(2x)/2x<0.51ExponentialIn(22x)/2x0.5

Sine

SineIn(x)={0forx01cos(0.5πx)for0<x<11forx1SineOut(x)=1SineIn(1x)SineInOut(x)={SineIn(2x)/2x<0.51SineIn(22x)/2x0.5

Back

BackIn(x)={0forx03.5949095x32.5949095x2for0<x<11forx1BackOut(x)=1BackIn(1x)BackInOut(x)={BackIn(2x)/2x<0.51BackIn(22x)/2x0.5

Notes

Ease rate input is limited between 0.10 and 20.00 but can be edited externally to other values.

Ease In values below 1% and Ease In Out values below 0.5% and above 99.5% are linearly approximated.

Trigonometric functions are approximated and linearly interpolated using a table of 101 points (1% divisions). This is much more noticeable on elastic easings with very low ease rate and not noticeable in the case of sine easings.

Last updated: