Colors and models: introduction
Color is not a property of an object or of light. It is a sensation produced in the eye and brain when light of a particular composition falls on the retina. To compute with color, it has to be described by a model.
Visible light
Light is electromagnetic radiation. The eye responds to wavelengths from roughly 380 to 780 nanometers. We see the shortest as violet, then blue, green, yellow, orange, and red at the longest. Beyond this range lie ultraviolet and infrared, which the eye does not register.
Almost no light around us has a single wavelength. Daylight, a light bulb or a screen are mixtures of many wavelengths at different intensities. Such a mixture is described by its spectral distribution: a plot of intensity against wavelength.
Color is a sensation
The eye does not measure the whole spectral distribution. It has only three kinds of cones, the color-sensitive cells, and each reports one number to the brain: how strongly it was stimulated (see the model of the eye). All color information comes down to three numbers.
That leads to the most important fact of color theory: color is three-dimensional. Every color model, from RGB to CIELAB, describes it with three numbers (CMYK has four, but the fourth comes from the needs of printing, not of vision).
Metamerism
Since the eye sees only three numbers, two lights with entirely different spectral distributions can produce the same three cone responses. They then look identical. This is called metamerism, and such pairs of colors are metamers.
Metamerism is what makes displays work: yellow on a monitor is a mix of red and green light, not light at 580 nm, but the eye sees them the same. It also has a downside: two fabrics that look identical in a shop can differ clearly in daylight, because under different lighting they stop being metamers.
Three attributes of color
People usually describe color by three attributes:
- hue: red, yellow, green, blue, purple,
- saturation: how much the color differs from gray,
- brightness: how much light there seems to be.
The HLS, HSI and HSV models imitate this kind of description. In colorimetry, though, "brightness" and "saturation" have several distinct, precisely defined meanings, covered in the section on color measures.
Why color models
A color model is a way of writing a color as numbers. Different uses need different models:
| Need | Model |
|---|---|
| driving a display, camera, scanner | RGB |
| printing | CMYK |
| intuitive color picking | HSV, HSL |
| device-independent description | CIE XYZ |
| comparing colors as people see them | CIELAB, CIELUV |
| image transmission and compression | YUV, YIQ, YCbCr |
The following pages of this section cover these models one by one, and the part on conversions shows how to convert between them.