Functions
Const clamp
- clamp(num: number, min: number, max: number): number
-
Parameters
-
num: number
-
min: number
-
max: number
Returns number
Const isPowerOf2
- isPowerOf2(value: number): boolean
-
Parameters
Returns boolean
Const mapNumberRange
- mapNumberRange(val: number, inMin: number, inMax: number, outMin: number, outMax: number): number
-
Parameters
-
val: number
-
inMin: number
-
inMax: number
-
outMin: number
-
outMax: number
Returns number
Const normalizeNumber
- normalizeNumber(min: number, max: number, val: number): number
-
Parameters
-
min: number
-
max: number
-
val: number
Returns number
Const triangleWave
- triangleWave(t: number): number
-
Parameters
Returns number
Clamp number to a given range