Skip to content

lerp

Linearly interpolates between two numbers.

Usage

lerp(0, 10, 0.5); // => 5
lerp(5, 15, 0.2); // => 7
lerp(-10, 10, 0.75); // => 5

Installation

Terminal window
npx atmx add helper lerp