Color Space and Color Profiles
This page presents an in-depth discussion of the methods used to reproduce color in digital photography.
What's a color model?
What's a color space?
What's a color profile?
Commonly used color spaces
Setting up Photoshop color settings
Opening raw files into a working color space
Converting between color profiles
Assigning profiles to an unprofiled image
At its core, digital photography works by turning colors into numbers. There are a number of different ways of doing so. Some use the physics of light waves, some rely on the way the eye perceives color, and some are built around the way ink creates colors. Each of these color models is useful in different ways. In order to understand how to preserve color as you change from one model to another, it's helpful to have a basic understanding of what a color model is: a way to turn colors into numbers with a mathematical formula.
RGB is a color model that uses the three primary (red, green, blue) additive colors, which can be mixed to make all other colors. RGB builds its model on different colors of light added together, where the mixture of all three colors produces white light, as shown in Figure 1. Digital cameras produce RGB images, and monitors display RGB images.
|Figure 1This illustration is a representation of RGB color. This model assumes you start with darkness and add light to make new colors.|
CMYK is a color model based on subtracting light – the cyan, magenta, yellow and black inks used in most commercial color printing (books, magazines, etc.) Inks absorb colored light, which is why the model is called a subtractive one. CMYK is commonly referred to as process color, and there are many individual color spaces that use the CMYK color model.
|Figure 2 This illustration shows how CMYK color works. Ink on paper absorbs certain colors and reflects others. Cyan, Magenta and Yellow are combined to make each color. Black is used to get extra punch in the image.|
CIELAB and CIE XYZ are similar color models designed to approximate human vision. Because these color models include so many colors, they are both used when translating from one color model, such as RGB, to another, such as CMYK. These are referred to as profile connection spaces (PCS). For instance, Photoshop uses CIELAB as a reference color space when it converts from one RGB profile to another RGB color space. Photoshop uses CIE XYZ when it converts from the RGB color mode to the CMYK color mode. It's possible to use the CIELAB color space for image editing in Photoshop, although few choose it for that purpose since it is not as easy to understand as the other color models.
|Figure 3 L*a*b* color uses three channels to represent the theoretical range of human vision: Lightness (L*), and two color channels of opposing values of red-green (a*) and yellow-blue (b*). L*a*b* color is different to RGB and CMYK in that it is both a color model and a color space. It is also a device-independent color space, meaning that its color values are absolute and not tied to any particular piece of hardware.
A color space is a specific implementation of a color model. There are many RGB and CMYK color spaces. The video below shows a three-dimensional representation of several color spaces and how they relate to each other.
|Figure 4Color spaces in 3-D. Press the icon at the bottom right to go to full screen.|
You can see that some color spaces, like Prophoto RGB, contain all of the colors that are in Adobe RGB (1998), and you can see that Adobe RGB contains nearly everything that is in sRGB. When you convert from one color space to another, any colors that are outside the destination space are "out of Gamut" colors since they can't be represented accurately by the new space. You can check to see which colors will be either clipped off or re-mapped into the smaller color space. Whether colors are clipped or remapped will depend on the rendering intent—which is a term for the mathematical algorithm used to convert from one color space to another.
The terms color space and color profile can often be used interchangeably, since a profile is a description of a specific color space. There is further discussion of the nature of color spaces in the next section.
A color profile is a numerical model of a color space. Operating systems and programs need to have access to a profile that describes the meaning of the color values in order to interpret the color correctly. Proper color management requires all image files to have an embedded profile.
The two types of color profiles
There are two types of profiles: matrix-based and table-based.
- Matrix-based profiles use mathematical formulas to describe the three-dimensional color space. They can be relatively small. They are most appropriate for working spaces and for use as embedded profiles.
- Table-based profiles, as the name implies, use a large table of sample points – called a Look Up Table or LUT – to define the three-dimensional color space. These profiles are more customizable, and are therefore more useful when translating color information from one space to another, or in describing the color characteristics of a particular device. Because they rely on many data points, they are much larger.
Device-dependent and device-independent color spaces
Some color profiles are purely theoretical and describe a way to turn color into numbers. These are device independent. Some profiles are made to compensate for the color signature of a device like a printer or monitor. These are known as device-dependent color spaces.
Most photographers will have to deal with a handful of different color spaces in their work. In general, these can be divided into three groups: Working, Device and Output spaces. Let's take a look at each group and list some of the options you'll see in each.
Working color spaces are color models that are well suited to image editing tasks such as color and tone adjustments. Ideally, these are large color spaces, offering the photographer the ability to choose between a wide gamut of colors. There's no single ideal color space but there are a few very good choices.
- Adobe RGB (1998) - As the name implies, this color space was created by Adobe in the late 90s, when Photoshop implemented full color management. Although Adobe never intended this color space to be the universal standard, it is widely supported. Most DSLR cameras offer this as a color space choice for JPEG creation. While Adobe RGB does not contain as many colors as ProPhotoRGB, it's easier to use and a very good choice for both 8-bit and 16-bit image editing.
- ProPhoto RGB - This color space was designed as a universal standard for high-bit image editing, and includes all the colors that the human eye can see. ProPhoto RGB is a very popular color space for experienced Photoshop users. Because the space is so wide, it's not appropriate for 8-bit images. ProPhoto RGB is not always the best choice for a working space. Because 15% of the color space is beyond the range of human vision, color mapping is happening in ways that are impossible to see. Some images will suffer when they are converted from ProPhoto RGB to a CMYK space because these out-of-gamut colors map to the destination space in unwanted ways.
- CIELAB - This color space is used internally by Photoshop during color space conversions. Some people have found interesting ways to use CIELAB space to manipulate images, since the luminance is totally separate from the color information. However, CIELAB is not an easy space to use since it's not intuitive for most people. Images that are in CIELAB space also don't have full support in Photoshop for adjustment layers and other non-destructive imaging tools.
Photographers will most commonly run into device-dependent color spaces when profiling monitors, desktop printers or sending images out for CMYK printing.
- Monitor RGB - Modern monitors include a factory-created profile that is loaded into the monitor's firmware and is communicated to your computer via the monitor connection cable. If you want your monitor to do the best possible job reproducing your images, you should create a custom profile for it.
- Desktop printer profile - Your printer comes with profiles in the driver software. You can create a custom profile for your printer if you want to maximize its color fidelity.
When images are sent from one person to another, it can be appropriate to consider converting the working space. The choice of a delivery space is often dependent on what the photographer knows about the recipient of the image. In some cases, much is known about the recipient, or the exact delivery space is precisely specified. Other times, images get sent out with little indication of how they will be treated on the other end.
- sRGB - This color space is a small color space – it's often thought of as a lowest common denominator. sRGB is very similar to older monitor spaces and, in fact, it's common for unmanaged computers to assume that an image is in the monitor color space. This makes sRGB a good choice to send to unknown users. At the moment, sRGB is the only appropriate choice for images uploaded to the web since most web browsers don't support any color management. Additionally, sRGB is a very good choice for images sent to minilabs, especially if there is no custom profile available. Because sRGB is not a wide color space, it's not appropriate as a working space.
- Adobe RGB - This is probably the most often-requested color space for delivery, if a color space is specified. It offers a good gamut and very wide support. Note that Adobe RGB images that are uploaded to websites without conversion to sRGB will generally appear dark and muted as shown in Figure 5.
|Figure 4 Here we see two examples of an image. The left-hand image has been converted to sRGB, and should look reasonably accurate to viewers who have profiled their monitors. The right-hand image is in Adobe RGB, and will look dark and muted to most viewers, even if they have a profiled monitor, since most web browsers do not make use of the embedded profile. If the images look the same, your browser and operating system are correctly color managing the page.|
- CMYK profile - When you send an image off for CMYK printing, you can either use a generic CMYK profile, or, if the printer can supply one, you can convert the image to a custom color space. You will find much more information here:
In order to get Photoshop to color manage optimally, you'll want to check a few options that are part of the Color Settings dialog (available in the Edit menu.) A good setup is shown below.
|Figure 5 Make sure to set Photoshop's color settings to warn you whenever a profile is missing. If you work mostly in 8 bit, set your RGB space to Adobe RGB. If you often work in 16 bit, you may want to choose ProPhoto RGB.|
You can also download the dpBestflow®.csf file here (right-click to save file). Once it's been downloaded, you can open Photoshop's color settings dialog and import the settings. Click "Load" and find the file you downloaded. Photoshop will now be set to our recommended settings.
|Figure 6 The Load button in Photoshop's Color Settings dialog lets you import a preset configuration.|
Camera raw images don't have a conventional profile attached to them, but they will get one as soon as you open them and create a rendered file such as a TIFF, JPEG or PSD. You'll want to choose the working space as the destination if you're going to do further manipulation of the image. If you are creating derivative files directly for output, you'll want to choose the proper delivery space. The video below shows you how to set this up in Adobe Camera Raw.
|Figure 7 This video shows you how to assign a profile as you open a file in Adobe Camera Raw.|
There are a number of times when you will want to convert a file from one color space to another. Usually this is a conversion from a working space to some kind of output space. If that output space is smaller than the working space (and it usually is) then you will be changing the colors. The settings you use to make these changes can help you preserve the color in your images.
Rendering intents used when converting between color profiles
Rendering intent refers to the algorithm or mathematical model used to handle conversions from one color space or profile to another. The four methods (Perceptual, Saturation, Relative Colorimetric, and Absolute Colorimetric) are defined in the ICC profile specification. Perceptual and Saturation use gamut compression to remap source colors to fit the destination. Relative and Absolute Colorimetric utilize gamut clipping to remap to the closest reproducible hue. The easiest way to think about this is that gamut clipping eliminates out- of-gamut colors but leaves the in-gamut colors alone. Gamut compression, however, pushes all the colors around to make them fit into the smaller color space. With gamut compression, the most out-of-gamut colors are changed the most, but even in-gamut colors may be changed slightly.
The best way to learn which method to use for which images is to check the conversion with "soft proofing” in Photoshop. You can see the effect of each different method before making the actual change. Again, there's no universal best practice here other than to preserve the intention of the photographer. As a starting point, here's a quick guide to the use of each rendering intent:
- Perceptual is for preserving some relationship between out-of-gamut colors, although it may change the color accuracy of in-gamut colors. Perceptual rendering sometimes makes certain images look better when printed or converted to the CMYK color space.
- Relative Colorimetric maintains the color accuracy of in-gamut colors, although it clips out-of-gamut colors. Most color conversions and prints use this rendering intent.
- Saturation rendering intent tries to preserve saturated colors, and is most useful when trying to retain color purity when converting into a larger color space. It is not usually recommended for digital photo images since it doesn’t attempt to maintain color realism.
- Absolute Colorimetric is used most often for proofing – that is mimicking the color rendition of a specific device and/or paper combination. It does this by moving the white point to reflect the relative whiteness of the target device or substrate being printed on.
The video in Figure 8 shows you how the color is affected when converting a colorful image from a wide gamut space to a smaller gamut space.
If your image does not have an embedded profile, you will need to assign one on the way in to Photoshop. You’ll need to experiment with various profiles until you find one that makes the image look its best. As a general rule of thumb, most RGB images that don't have an embedded profile look best when assigned an sRGB profile. Many digital point-and-shoot cameras capture images in sRGB color space but don't automatically embed the profile in the image file. Once you have assigned a profile and saved the image file with the profile embedded, the image file can be color managed.
Figure 8 This video shows how to assign a profile to an untagged image.