BO.filters.Scaler Class
Scales up an input value from its min and max range to a specified minimum to maximum range. See Breakout/examples/filters/scaler.html for an example application.
Constructor
BO.filters.Scaler
(
-
inMin -
inMax -
outMin -
outMax -
type -
limiter
Parameters:
-
inMinNumberminimum input value
-
inMaxNumbermaximum input value
-
outMinNumberminimum output value
-
outMaxNumbermaximum output value
-
typeFunctionThe function used to map the input curve
-
limiterBooleanWhether or not to restrict the input value if it exceeds the specified range.
Item Index
Methods
- processSample
- Scaler.CUBE static
- Scaler.CUBE_ROOT static
- Scaler.LINEAR static
- Scaler.SQUARE static
- Scaler.SQUARE_ROOT static
Methods
processSample
(
Number
protected
-
val
Process the value to be filtered and return the filtered result.
Parameters:
-
valNumberThe input value to be filtered.
Returns:
Number:
The resulting value after applying the filter.
Scaler.CUBE
()
static
y = x^4
Scaler.CUBE_ROOT
()
static
y = pow(x, 1/4)
Scaler.LINEAR
()
static
y = x
Scaler.SQUARE
()
static
y = x * x
Scaler.SQUARE_ROOT
()
static
y = sqrt(x)
