map_to_range

Function map_to_range 

Source
pub fn map_to_range<T: Float, X: Base<T>>(
    v: X,
    in_start: X,
    in_end: X,
    out_start: X,
    out_end: X,
) -> X
Expand description

remap v within in_start -> in_end range to the new range out_start -> out_end