long map( long value, long fromLow, long fromHigh, long toLow, long toHigh );
long map( long value, long fromLow, long fromHigh, long toLow, long toHigh );
Re-maps a number from one range to another. That is, a value of fromLow would get mapped to toLow, a value of fromHigh to toHigh, values in-between to values in-between, etc.
|
Parameters |
Description |
|
long value |
the number to map |
|
long fromLow |
the lower bound of the value's current range |
|
long fromHigh |
the upper bound of the value's current range |
|
long toLow |
the lower bound of the value's target range |
|
long toHigh |
the upper bound of the value's target range |
The mapped value.
WMath.h