fromRGB

public static Color fromRGB(int red, int green, int blue)

Creates new Color object from red, green, and blue

Return

new Color object for the red, green, blue

Parameters

red

integer from 0-255

green

integer from 0-255

blue

integer from 0-255

Throws

if any value is strictly >255 or <0


public static Color fromRGB(int rgb)

Creates new color object from an integer that contains the red, green, and blue bytes in the lowest order 24 bits.

Return

new color object for specified values

Parameters

rgb

the integer storing the red, green, and blue values

Throws

if any data is in the highest order 8 bits