Gamma correction basically refers to the ability to correct for differences
in how computers (and especially computer monitors) interpret color values.
Web authors in particular are probably aware that Macintosh-generated images
tend to look too dark on PCs, and PC-generated images tend to look too light
and washed out on Macs. An image that looks good on an SGI workstation won't
look right on either a Macintosh or a PC, and even a PC-created image won't
look right on all PCs.
Gamma information is a partial solution. It's a means of associating a
single number with a computer display system, in an attempt to characterize
the tricky physics lurking within a graphics card's digital-to-analog
converter (RAMDAC) and within a monitor's high-voltage electron gun and
display phosphors. Gamma is only a first approximation that accounts for
overall "brightness", but it is generally sufficient for casual users.
More demanding users will additionally want to adjust for differences in the
individual red, green, and blue channels--the so-called chromaticity
values, which are also supported by PNG. Even this is merely a second
approximation, however.
The absolute best solution currently available is to use a complete color
management system, which allows one to take into account things like the
viewing environment (a "dim surround", for example) and its interaction
with the human visual system. The International Color Consortium has defined
a profile format that describes the relationship between an input color space
(say, a digital camera or scanner) and the output color space that the user
sees. This is the most general way to account for cross-platform differences
(and, of course, PNG supports it via the iCCP chunk), but its flexibility
comes at a cost: it tends to add at least 250 bytes and often 2,000 bytes
or more to every image.
Fortunately, a new proposal for operating systems and physical devices avoids
the overhead of a complete ICC profile. Called sRGB, for Standard RGB
color space, it defines just that: a standard, unified color space that
devices can support, thereby allowing true color management with minimal
file overhead and no need for the user to wade through a complicated end-to-end
calibration procedure. As of January 1999, the sRGB proposal was in
``Committee Draft for Voting,'' and it should be approved as an international
standard[3]
by mid-1999; conformant devices should start appearing shortly thereafter.
PNG supports sRGB via a chunk called, logically enough, sRGB.
Gamma, chromaticity, and color management are described in more detail in
Chapter 10, "Gamma Correction and Precision Color"; PNG's basic structure, including the means by which it can be
officially or unofficially extended, is covered in Chapter 8, "PNG Basics" and Chapter 11, "PNG Options and Extensions".