toInt method

int toInt()

Returns the 16-bit integer representation of this color.

Implementation

int toInt() {
  return (red << 11) | (green << 5) | blue;
}