Skip to content

Instantly share code, notes, and snippets.

View KennethMurugu's full-sized avatar
🎯
Focusing

Kenneth Murugu KennethMurugu

🎯
Focusing
View GitHub Profile
@KennethMurugu
KennethMurugu / easing.js
Created July 25, 2017 10:20 — forked from gre/easing.js
Simple Easing Functions in Javascript - see https://github.com/gre/bezier-easing
/*
* Easing Functions - inspired from http://gizma.com/easing/
* only considering the t value for the range [0, 1] => [0, 1]
*/
EasingFunctions = {
// no easing, no acceleration
linear: function (t) { return t },
// accelerating from zero velocity
easeInQuad: function (t) { return t*t },
// decelerating to zero velocity