July 13, 2006

HSB

For those of you who know the HSB colorspace, and enough math/programming to understand what this says...what the hell were they thinking?

-----

public static Color getHSBColor(float h,
float s,
float b)

Creates a Color object based on the specified values for the HSB color model.

The s and b components should be floating-point values between zero and one (numbers in the range 0.0-1.0). The h component can be any floating-point number. The floor of this number is subtracted from it to create a fraction between 0 and 1. This fractional number is then multiplied by 360 to produce the hue angle in the HSB color model.

Parameters:
h - the hue component
s - the saturation of the color
b - the brightness of the color
Returns:
a Color object with the specified hue, saturation, and brightness.
Since:
JDK1.0

Posted by fugimax at July 13, 2006 04:09 PM
Comments
Post a comment









Remember personal info?