linearstep
An analogue to GLSL's smoothstep, it linearly remaps the values of x between a and b to the range [0, 1], and clamps values outside this range. Overloaded for float and vector types
float linearstep(float a, float b, float x);
vec2 linearstep(float a, float b, vec2 x);
vec3 linearstep(float a, float b, vec3 x);
vec4 linearstep(float a, float b, vec4 x);
vec2 linearstep(vec2 a, vec2 b, vec2 x);
vec3 linearstep(vec3 a, vec3 b, vec3 x);
vec4 linearstep(vec4 a, vec4 b, vec4 x);