Fade
Description
A mapping from input values in a given range [a..b] to a normalized fade range [0..1].
The string representation (see Fade.ToString) has the following format:
-
'(0:a|b:1)'
a := the input value that is mapped to fade value zero
b := the input value that is mapped to fade value one -
'(0:)'
AlwaysZero -
'(:1)'
AlwaysOne
Public / Constants
Public / Methods
Add
Adds the given value in to fade range boundaries:
before: [a .. b] Add(x) after: [a + x .. b + x]
Mul
Multiplies the fade range boundaries with the given value in:
before: [a .. b] Mul(x) after: [a * x .. b * x]
- See also
ToLinearD
Returns this fade range as a linear function:
y = m * x + b
where y
is the fade range value and x
is the input value.