Protected
_colorsThe list of colors that comprise the gradient.
Protected
_componentComponent values grouped by channel.
Protected
_domainThe stop values for each color.
Protected
Optional
_interpolatedThe version of the gradient that was interpolated during the last getComponents call.
Protected
Optional
_interpolatorThe interpolation factory that was used during the last getComponents call.
Protected
_interpolatorsColor component interpolators that were produced by _interpolatorFactory for components provided by the _model for colors with cumulative version _interpolatedVersion.
Protected
Optional
_modelThe model that was requested during the last getComponents call.
Protected
_tempColor components returned by the getComponents method.
The integer value that is incremented when an underlying color is changed.
Returns the color at the given position in the gradient.
The value from the gradient domain for which the color is requested.
Optional
model: ColorModel = RGBThe color model that should be used for interpolation.
Optional
interpolatorFactory: InterpolatorFactory = lerpThe function that returns a color component interpolator.
The new Color instance.
Returns color components that correspond to a value from the gradient domain.
Note: Don't keep reference to the returned array because it is reused between getComponents invocations.
The color model that provides the components for interpolation.
The domain value.
The function that returns an interpolator. If the same function identity is provided on each call, interpolation result is cached for better performance.
The read-only components array.
Provides color gradient manipulation API that is extensible via plugins.