Class GradientHelper
Constructors
constructor
-
Returns GradientHelper
Methods
StaticGet Current Gradient
-
GetCurrentGradient(
ratio: number,
gradients: IValueGradient[],
updateFunc: (
current: IValueGradient,
next: IValueGradient,
scale: number,
) => void,
): voidGets the current gradient from an array of IValueGradient
Parameters
- ratio: number
defines the current ratio to get
- gradients: IValueGradient[]
defines the array of IValueGradient
- updateFunc: (current: IValueGradient, next: IValueGradient, scale: number) => void
defines the callback function used to get the final value from the selected gradients
Returns void
- ratio: number
Helper used to simplify some generic gradient tasks