ColorHelper

Talks about the colorHelper class

ColorHelper

This class provides helper methods for working with colors.

Methods

getColor(int red, int green, int blue)

Returns a color as an integer value given its red, green and blue components.

Parameter
Description

red

The red component of the color

green

The green component of the color

blue

The blue component of the color

Returns: The color as an integer value.

getColor(int red, int green, int blue, int alpha)

Returns a color as an integer value given its red, green, blue and alpha components.

Parameter
Description

red

The red component of the color

green

The green component of the color

blue

The blue component of the color

alpha

The alpha component of the color

Returns: The color as an integer value.

getColorFromInt(int color)

Converts an integer value to a Color object.

Parameter
Description

color

The integer value representing the color

Returns: A Color object representing the given integer value.

getColorFromHue(float hue)

Returns a color as an integer value given its hue.

Parameter
Description

hue

The hue of the color

Returns: The color as an integer value.

ColorToInt(Color color)

Converts a Color object to an integer value.

Parameter
Description

color

The Color object to convert

Returns: The integer representation of the given Color object.