Package com.oorian.css.color
Class Hsb
java.lang.Object
com.oorian.css.color.Hsb
Encapsulates the attributes used for setting an HSB color.
HSB is an alternative to RGB for specifying a color. HSB stands for Hue, Saturation, and Brightness, where Hue defines the actual color with a value of 0 to 360. Saturation defines the purity of the color with a value of 0 to 100. And Brightness is defined with a value from 0 (black) to 100 (white).
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
h
public int hHue component (0 - 360). -
s
public int sSaturation component (0 - 100). -
b
public int bBrightness component (0 - 100).
-
-
Constructor Details
-
Hsb
public Hsb()Creates a default HSB object with HSB = 0, 0, 0. -
Hsb
public Hsb(int h, int s, int b) Creates an HSB object with the specified HSB values.- Parameters:
h- Hue component (0 - 360).s- Saturation component (0 - 100).b- Brightness component (0 - 100).
-
Hsb
Copy constructor.- Parameters:
hsb- HSB object to copy.
-
-
Method Details