Color Space, Page 1

Everything would be simpler if all image files used the same color space. (0,0,0) would be black. (The first number is red. The second number is green, and the third number is blue. The numbers range from 0 to 255.) (255,0,0) is red, (0,255,0) is green, (0,0,255) is blue, (255,255,255) is white, and (128,128,128) is medium gray. Simple, effective, but there are at least two realities that need to be considered:

1. The trained human eye can distinguish about 200 grayshades. The range of 0 to 255 is what can be represented with 8 binary bits. By far the majority of image files use 8 bits for red, 8 bits for green, and 8 bits for blue, and are called 8-bit color files. So 255 grayshades, even if uniformly spaced insofar as human perception is concerned is just barely enough.

But, there's a problem. What do we mean by "uniformly spaced?" From the perspective of a computer monitor, uniformly spaced could mean that the additional light produced by a, e.g., red pixel for one additional value is uniform. If we go from (0,0,0) to (1,0,0), the additional red light is the same as going from (128,0,0) to (129,0,0), or from (254,0,0) to (255,0,0). Seems reasonable. But, the human eye is not linear. So "uniformly spaced" from the monitor's perspective isn't uniformly spaced from a human eye perspective.

Or, consider the perspective of an ink jet printer, putting yellow, magenta, cyan, and black inks on a page. (Many printers use more than just 4 colors, but let's not let this get more complicated than it needs to be.) More red is obtained by putting less cyan ink on the page. Cyan ink passes green and blue light, but absorbs red light. But inks are nonlinear, so uniform increments of ink don't result in uniform changes in red light, and uniform changes in red light aren't perceived as being uniform by the human eye.

The bottom line so far: those 8 bits of color information might or might not be enough. Let's say we have a very slowly changing area of sky that varies from a slightly lighter blue to a slightly darker blue. There could be a lot of pixels having the value (200,100,50), and nearby there are a lot of pixels having a slightly darker value of (199,100,50). There will be a dividing line where above the line, all pixels have the first color, and below that line all pixels have the second color. If we see a visible dividing line between the two areas (and additional dividing lines further down the image), that's bad (see above).

So, to minimize the possibility of this happening, color space algorithms are used for mapping one set of information into another set, so as to spread those 8 bits (256 values per color) of information out as usefully as possible.

Not everyone agrees on what is the best way to accomplish this, and there are multiple perspectives on what is most important. The two most useful color space algorithms are sRGB and Adobe 1998.

The color space issue is already complicated enough, but there's another issue: not all colors are in gamut. Continued, below...Continue to colorspace Pg 2

Return to articles   Ahead to Colorspace Page 2   Home