toRGB

Returns the color in RGB representation. The result has the following properties:

  • r -- red component as floating point between 0 and 1
  • g -- green component
  • b -- blue component
  • a -- alpha

This does not modify the current object, it creates a new one instead.

Returns

Object An object with r, g, b and a fields.

In this article