Skip to content

Instantly share code, notes, and snippets.

@marioecg
Created January 8, 2020 03:59
Show Gist options
  • Save marioecg/26ed0c2b0686acc4e2d7c5aa6e786edb to your computer and use it in GitHub Desktop.
Save marioecg/26ed0c2b0686acc4e2d7c5aa6e786edb to your computer and use it in GitHub Desktop.
Linear interpolation (lerp or mix)
function lerp(start, end, t) {
return start * (1 - t) + end * t;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment