They can be used to customize the canvas drawing operations using a gradient.
The gradient object can be further customized using addColorStop.
See also the CanvasGradient documentation at MDN.
Adds a new color stop, defined by an offset and a color.
|offset||number||A number between 0 and 1 (inclusive), representing the position of the color stop.|
|color||string||A CSS color representing the color of the stop.|
See also addColorStop at MDN.