mapRange function
Implementation
double mapRange(double value, double fromMin, double fromMax, double toMin, double toMax) {
final double t = inverseLerp(fromMin, fromMax, value);
return lerp(toMin, toMax, t);
}
double mapRange(double value, double fromMin, double fromMax, double toMin, double toMax) {
final double t = inverseLerp(fromMin, fromMax, value);
return lerp(toMin, toMax, t);
}