limp is a made up abbreviation for linear interval map, which linearly maps
a scalar value x0, that's in a
scalar interval u0: [min: number, max: number] to
a scalar output return value x1, that's in the
scalar interval u1: [min: number, max: number]
the math equation is simply x1 = u1[0] + (x - u0[0]) * (u1[1] - u1[0]) / (u0[1] - u0[0]).
which is basically doing inverse_lerp on x0 to find t, then applying lerp onto interval u1 with the found t
limp
is a made up abbreviation for linear interval map, which linearly mapsx0
, that's in au0: [min: number, max: number]
tox1
, that's in theu1: [min: number, max: number]
the math equation is simply
x1 = u1[0] + (x - u0[0]) * (u1[1] - u1[0]) / (u0[1] - u0[0])
.which is basically doing inverse_lerp on
x0
to findt
, then applying lerp onto intervalu1
with the foundt