model for representing color
by describing its attributes instead of the other colors which would be combined to create it, such as RGB
. It is vaguely similar to YUV
in that it segregates luminance
. This will be a simple overview and brief intorduction, lets take a look. (for a more technical description see HSL
The H (Hue
refers to the actual shade
of the color, such as green
, or purple
. In implementation the value is a range from 0 to some maximum value, however technically the values all reside within a loop
. The lowest value is actually adjacent to the highest value, such that there is no end or beginning. This is useful for among other things, easily roating the spectrum of an image, or selecting a color in an image without regard to how bright or saturated it is. It should be understood that when the other two components have very low values, slight fluctations can cause a great deal of error in calculating the Hue, thus making it wildly innacurate.
The next component is S. S is for saturation
. This describes how much color is present. That is, the lower the saturation value the closer the color is to grey
, the higher the value the more vibrant
it is. What this translates to in RGB space is increasing or decreasing the delta between the Red, Green, and Blue values while maintaining their correct proportions to produce the desired color. Think of hue as the actual color, and the saturation as how much shows up. Saturation is represented as a simple minimum or maximum value.
And of course, L brings us Luminance
. This is the amount of light that is present, the color will appear dim
depending on the luminance value. Low values will correspond to darker
colors, and higher values to a brighter
color, at the extreme low end of the range, it will force the color to black
-though not to white at the high end.
The three are then combined as a triplet to represent a single color. There are some disadvantages, for example the system was developed without taking into consideration the non-linearity
of perception of color
space for display. A luminance value of 50% will not necessarily percieved to be half as bright as a luminance value of 100%, though it is represented as such. For more information, try consulting books covering video, image processing, and different colorspace representations.