Lerp is used to blend between two things!
It has three inputs: ( a, b, t )
a = start value
b = end value
t = how far we should go from start to end, as a percentage
Here it is in action!⚡blending a value, position, color and an angle!
Mahtf.Lerp - values
Mathf.LerpAngle - angles
Color.Lerp - colors
Vector#.Lerp - positions
Vector#.Slerp - directions
Quaternion.Slerp - rotations
#unitytips
a(1-t) + bt
weighted sum interpretation, where both contribute a total of 1, trading off influence
a + t(b-a)
this one originates from a, moving toward b by adding the displacement scaled by t
oh, and, these two are mathematically equivalent!
here's a long thread on my love for Béziér curves, if you're interested💖