ease
ease copied to clipboard
Easing functions in #golang.
Easing Functions in Go
Installation
go get -u github.com/fogleman/ease
Documentation
https://godoc.org/github.com/fogleman/ease
Usage
All easing functions take a float64
and return a float64
. The input should be between 0 and 1, inclusive.
t = ease.OutElastic(t)
Some easing functions have extra parameters, like period
. Here is an example:
var f ease.Function
f = ease.OutElasticFunction(0.5)
t = f(t)
Or, simply...
t = ease.OutElasticFunction(0.5)(t)