lerp
Computes the linear interpolation of two values.
const n = Math.lerp(0.0, 2.0, 0.5); // returns 1.0
Content copied to clipboard
Return
The linearly interpolated value.
Parameters
p
The start value to interpolate.
q
The end value to interpolate.
time
The time of interpolation generally in the range [0.0, 1.0]
.