This page Copyright (c) C F Systems, 2000, 2001, 2002

Routine Color Balancing?

One of the first tips posted on this site was a means of dealing with Color Balancing Difficult Cases, intended to help when color balance is so far off that routine methods do not produce satisfactory results. That was because there already seemed to be plenty of tips available about routine color balancing. Since then we have realized that most of the available tips on routine color balancing suffer from varying degrees of misinformation and have left more than a little confusion in their wake. The truly strange examples of color balance that abound in professional photo magazines seem to reflect a basic misunderstanding of the available tools and what they do, even allowing that some of the strangeness is intended as artistic expression. Such confusion is not too surprising, since Photoshop tools are not at all straightforward in the way color balance is addressed. Here we will deal with routine color balancing using the Photoshop Levels tool. If you are happy with what Photoshop's Image→Adjustments→Auto Color does for you, read no further, but if you have a nagging feeling that even non-automatic color balancing never quite works as it should, read on. The How and Why section at the end explains the reasons behind the methods presented here for those already familiar with typical color balancing in Photoshop. Also see Color Integrity in Digital Imaging for a full explanation of what is happening and how it is the result of a vision psychology trap.

Especially for images which have color integrity, the following lengthy procedure can often be shortcut as explained on our Dunthorn Calibration page: Setting the Color Balance. However, you will need to become acquainted with the following (or with Dunthorn Calibration) in order to understand how the shortcut works.

Probably you are already aware that the Image→Adjustments→Levels tool has three color picker "eye-dropper" tools in the lower right corner. Please note that in using these tools, the "sample size" will be as last set for the color picker tool from the tool palette. For color balancing it is usually better to set the sample size to average a 5 x 5 or 3 x 3 pixel square rather than using a single pixel point sample.

These eye-dropper tools are described in the ToolTips, left to right, as setting the black, gray, and white point of the picture. Like so many things in Photoshop, that is both accurate and yet completely misleading. Actually, these are basic color adjustment tools that can be used to make color adjustments to the entire image so that selected reference areas come out completely neutral, or they can be used to match an image area to reference colors other than grays.

As with all initial image work, we strongly suggest that these preliminary color balance adjustments be done to 16 Bits/Channel images rather than 8 Bits/Channel images.

The "black point" picker tool is the most problematical and the black point should be the first adjustment made, if it is made. The tool is useful only in setting the neutral black but it is so poorly implemented that we do not recommend using it. If the black areas in the image need to be darker, examine the histogram for each channel, Red, Blue, and Green. In each case, move the leftmost slider under the histogram right until it is just barely before where the histogram data become visible. As we explain elsewhere, (The Black Point), this process actually degrades the image integrity slightly for images that are not stored at unity gamma (if you did not specifically set up to work with a unity gamma image, you almost certainly do not have unity gamma). In practical terms, the degradation is usually not enough to warrant taking the extra steps to eliminate it.

Contrary to what you might have read elsewhere, the center eye-dropper tool and the right eye-dropper tool perform very similar functions, but use two entirely different methods. Both of these eye-dropper tools will cause an adjustment in the entire image to make a selected spot in the image match a reference color. The so-called white or highlight picker tool makes the adjustment using the exact mathematical equivalent of the color correction filters that are used for color correction in conventional photography. That means the intensity of red light represented by each pixel in the image will be uniformly increased by the same percentage, so that a highlight picker adjustment might increase red by 5%, blue by 3% and green by 1%. The uniform treatment of the tri-color light intensities is the very basis of color photography, traditional or digital, and thus is critical to obtaining the best color balance. Within the limits of digital imaging, adjustments that can be achieved with this picker will generally be more satisfactory, making it worth the extra effort involved.

The so-called gray or mid-tone picker tool uses gamma adjustments on the individual color channels to achieve a match. Gamma adjustments on the individual color channels do not result in uniform treatment of light intensities of the three colors in each pixel, resulting in color distortions. While often not terribly objectionable visually, these distortions mean that the results are generally less satisfactory than produced by the highlight picker tool unless the adjustment required is extreme or previous digital processing of the image (in hardware or software) has been inappropriate and needs to be undone, a situation which is, unfortunately, becoming more common.

It is usually suggested that the "white point" picker be used to select the whitest point in the image. Be warned that in color technology "white point" has a rather different standard meaning than is implied here. But the real problem is that this approach often completely defeats the power of this tool. For different reasons, the whitest point in both digital and film images is likely to suffer from some color distortion, and working from the whitest point in the image forces the effect of this distortion on the entire image. It is usually much better to work from a gray; even a very light gray, but when "gray" is considered, the center "gray" picker naturally comes to mind. Despite the name, the better choice is to set the gray using the so-called white point picker.

Photoshop does not make this particularly easy to do. We will first describe a shortcut method and then the complete method, which requires additional steps and a prepared reference image. The "shortcut" method requires doing arithmetic, while in the complete method this can be avoided. (This "shortcut" is not the real shortcut mentioned above, which requires no math.)

For the first method, using the white point picker, select an area in the image known to be very light gray rather than white. A light tree branch or even a "white" flower or white garment can work well as long as the area is at least slightly darker than pure white – usually that means the area "has detail." Move the selection about the light gray patch, finishing where the entire image shows the best color balance. A truly neutral spot will show little variation in color balance, but may show quite a bit of variation in overall image intensity. At this point the highlights will be washed out, which effect we will fix in the next step.

After using the white point picker, the three channels will all show the rightmost slider on the histogram to have been moved to the left, as shown by the the Red channel below. The highlight point has been moved from 255 (full scale) to 184. The Blue and Green channels will also have similar changes. Select the channel with the least change; that is, with the highest number for the upper point. Here we have Red = 184 and we will take an example where Green = 175 and Blue = 168, so that Red is greatest. To unblock the highlights, we need to move the red highlight slider back to full brightness 255, or 255 – 184 = 71 counts. To preserve the color correction effect, we will also need to move both Green and Blue by the same amount, so that the Green highlight slider will be 175 + 71 = 246 and the Blue highlight slider will be 168 + 71 = 239. It is best to OK out of the Levels control at this point even if you wish to make further Levels changes.

After this change has been made, we can pay separate attention to whether the whitest whites in the picture are bright enough. If they are not, and if the Levels RGB histogram shows an area at the right end with essentially no data (similar to the short right tail on the Red histogram above), the highlight slider can be moved left to where the histogram data start to show up. If the whites are still not bright enough, the highlight slider for RGB can be moved further left but that will start to lose highlight detail. Our preferred method is to compress the highlights using the Curves tool.

This shortcut method, which uses the white point picker unaltered to select a gray, will force any gray to be white. The problem is that when selecting a middle gray, it is much more difficult to tell what you are doing because much of the image will go white when the highlight picker is used. Unaltered, the highlight picker forces a match to white (Red=255, Green = 255, Blue = 255) but it also can be used to force a match to any other color, darker grays or even specific colors. To do this, in the Levels dialog, double click on the highlight picker button. This will bring up the standard color picker dialog box:

Unless you are extremely experienced in dealing with color-by-the-numbers, this box is very little help in itself, but if you move the cursor outside the dialog box area, it becomes a picker/eye-dropper and will select color samples from any image displayed in the Photoshop work area. We use a file of reference colors and gradients for this purpose, but it is complex and tailored to our needs. The following is a small jpeg gradient file that will more clearly illustrate the principle. This illustrative example cannot be expected to serve satisfactorily as a complete working reference file, but it can serve as a starting point for developing a personalized reference file:

The left strip is a gray scale gradient, black at the top and white at the bottom. The next strip is a similar gradient for sky followed by three different gradients of skin tones. All of these were generated using the Photoshop gradient tool. (Download the example reference file.)

To use the complete method, load both the working image and the reference image into Photoshop, positioned so that you will be able to see the portion of the reference image you wish to match. Select the working image, start the Levels tool and double-click on the highlight picker button. When you move the cursor outside the color picker dialog box, the eye-dropper will appear. Pick a sample from the reference image, a gray or a sky tone or flesh tone, trying to match the lightness/darkness of the area to be selected on the working image. Once the color has been selected, OK out of the Color Picker and apply the picker/eye-dropper to the selected area of the working image. As with the shortcut method, try the eye-dropper on several points in the selected area, ending when the entire image looks best.

Final Adjusting Levels

Almost certainly, the reference color will have been either too dark or too light to match perfectly. If the mismatch is large, it is best to repeat the above, selecting a reference color that more nearly matches the lightness/darkness of the selected area. You may find it easier to zero in on selecting the correct reference color and so avoid doing the arithmetic described here and below. Technically, the color correction filter action is exact only when the lightness/darkness match is exact, but the differences are not significant for moderate mismatches. If the reference color was too light, the result will be similar to the shortcut method, with somewhat blocked highlights, and the same action should be taken to increase the highlight sliders for all three colors by the same amount.

If the reference color is too dark, the Output Levels of all three colors will need to be adjusted in a similar way:

Note that in this case the highlight slider is full scale 255, but the Output Level is 191. Again, the object is to move all three Output Levels by the same amount, and to move the largest value to full scale. We have Red = 191, and we will take an example where Green = 184 and Blue = 202. In this case Blue has the largest value and 255 – 202 = 53, so we will move all three Output Levels sliders by 53 counts. Blue will be 202 + 53 = 255, Red will be 191 + 53 = 244 and Green will be 184 + 53 = 237.

After either of the above adjustments has been made, we can pay separate attention to whether the whitest whites in the picture are bright enough. If they are not, and if the Levels RGB histogram shows an area at the right end with essentially no data (similar to the short right tail on the Red histogram above), the highlight slider for RGB can be moved left to where the histogram data start to show up. If the whites are still not bright enough the highlight slider can be moved further left but that will start to lose highlight detail. Our preferred method is to compress the highlights using the Curves tool.

When you OK out of the Levels tool after the above correction, Photoshop may or may not ask the question "Save the new target colors as defaults?" Answer this with "No" at least until you really understand what you are doing.

As we stated before, the center one of the picker buttons in the Levels tool, the "gray" picker, also matches a reference color, but does it using individual color gamma adjustments. This tool is used in a very similar manner to highlights picker, with one major difference. With the highlights picker, the match to the reference color is exact and so the result is typically also shifted darker or lighter in the process, which then has to be corrected. With the gray picker, the gamma adjustments are done so that the match is made to the reference color (or gray) while still trying to maintain the overall lightness/darkness and so a follow-up lightness/darkness adjustment is ordinarily not required.

When starting with an image file without known abnormalities, it is generally preferable to do color balancing using the highlight picker tool. The gray picker gamma adjustment is useful for more extreme cases and particularly for digital images which have been maladjusted somewhere along the route (usually by misapplied gamma or color gamma adjustments). A misapplied gamma adjustment can be more nearly corrected using another gamma adjustment than by a color correction filter. If you find that images produced using your normal path always seem to require gray picker or other color gamma adjustment, try doing the gamma adjustment first and then the highlight picker color correction adjustment. You may find a standard gamma adjustment that can be applied prior to color correction.

As we mentioned above, for images which have color integrity the shortcut explained on our Dunthorn Calibration page can be used:
Setting the Color Balance.

For the curious, it will be instructive to compare the color balances achieved for the same image using the highlight picker and the gray picker. If you have been routinely using the gray picker, you may be amazed to see the comparison to what you formerly thought was good color balance.

How and Why

Balancing color by first setting a white point and then a gray point has evolved from a good precedent for reasons that seem good on the surface. The precedent for setting the white point is the "color temperature" measurement which originated in photography to select color compensation filters for taking photographs and progressed to the "white balance" process which has been developed further in videography. In that process, the color of the light source (the actual "white point") is measured and used to set the filtration of the light or the electronic color sensitivities of a camera to achieve color balance in the images produced.

In working with existing electronic images, this has led to the similar concept of picking the brightest point in an image and shifting the values of each of the three colors (RGB) so that point becomes white. Because this "setting the white point" often does not do the job entirely satisfactorily, it is followed by "setting the gray point," which uses a "gamma" correction (the Levels center slider). The gamma correction makes its greatest changes in mid-tones, tapering off to leave both pure white and pure black unaltered, so the already set "white point" will not be disturbed by setting the gray point.

This sounds logical and indeed it often seems to work, but it also fairly often leads to very strange results because the central idea is flawed. In setting the white balance in live photography or videography, the color quality of the light source is measured. Since this light actually illuminates the objects in the image being photographed, it is an accurate measure of color balance. However, the brightest point in an electronic image is typically an object reflecting light from the source, and often is not a good measure of that source. It may have a tint. It also has been recorded in the least reliable range of the light sensitive media. Films taper off in sensitivity at high illumination, and the three colors (RGB) taper off differently, inducing a color cast relative to the rest of the image. Digital images are less graceful, going directly into "saturation," an extreme version of color cast.

So, what happens? When the brightest point in an image does turn out to be a good measure of the light source, "setting the white point" does an amazingly good job of establishing the color balance of the image. The reason for this is that the adjustment Photoshop uses has exactly the same action as color correction filters do in conventional photography – all reds are adjusted by the same red percentage adjustment, all greens are adjusted by the same green percentage adjustment, and all blues are adjusted by the same blue percentage adjustment. "Setting the gray point" is then a trivial touch-up and the method works fine.

When the brightest point is not a good measure of the light source – a common occurrence – "setting the white point" produces an image in which only the brightest whites are satisfactory. In effect, the color correction filters for the image have not been chosen correctly for the main part of the image and the result is an overall color cast. This is then "corrected" by "setting the gray point," which uses gamma correction to alter the colors, making the largest corrections in mid-tones and tapering off to no correction at all for the lightest and darkest areas. This will completely correct the color cast in the mid-tones only, so that only the brightest whites and the mid-tones are balanced, leaving a color cast in the rest of the image that varies with lightness or darkness, a truly strange effect you will begin to recognize now that you are aware of it. Typically, when this color balance problem is bad enough, it is further "corrected" using the Color Balance and/or the Hue/Saturation tools in Photoshop, leading to other effects you will begin to recognize. It is nearly impossible to restore correct color balance to an image once it has passed through this treatment.

To achieve good color balance, what has to happen, one way or another, is that the major correction be done with color correction filters, so that consistent percentage corrections for each of the three colors are made throughout the image. The easiest method to achieve this in Photoshop is by using the "white point" picker from the Levels tool to set a middle or middle-high gray or a color such as a sky tone or flesh tone as we explain in detail above. If necessary, that result can be tweaked using the rightmost (highlight) sliders for R, G, and B in the Levels tool until the main part of the image shows proper color balance. (These sliders behave like color correction filters.) Any remaining color casts are imperfections of the original image data or of expectations.

Image color imperfections usually take forms such as a color cast in the highlights, which areas can be selected and corrected without warping the color balance of the entire image. Do not try to fix highlight problems using the highlights setting of the Photoshop Color Balance tool on the entire image as it will change the color balance of the entire image and undo your earlier careful balance.

Expectation color imperfections usually result from mixed illumination sources. These occur because the eye can react differently to a scene and an image of that same scene. Objects in shade – illuminated by the sky – will have a different color balance than objects illuminated directly by the sun in the same image. Objects near a reflective colored surface will be partially illuminated by that colored reflection. In cases like these, the image should first be balanced using objects illuminated by the principle source. Objects with a different illumination source may then appear natural, but if not, regions with the different source can be selected and separately balanced. However, if the different light source is evident to a viewer of the image, as it is with sun and shade, a complete balance of such areas will not look natural and using only part of the correction will be more satisfactory.

If it is impossible to achieve a good general color balance of an image by applying the Levels "white" picker to mid or mid-high tones as explained above – and it does happen – you really do have a problem image, one with the problem built into its history. Badly processed film, electronic imaging equipment with poorly designed compensations, and scans of faded color photographs are common examples. Anything you find to make such images appear better is fair game and you will be ruining nothing when you try. You may even wish to try our methods described in
Color Balancing Difficult Cases.

The Black Point

We have barely mentioned the leftmost picker button in the Levels tool, the black point picker. The black point picker controls the leftmost histogram sliders of the Levels tool just as the white point picker controls the rightmost sliders. If we could work with a digital image in which the light intensities have been linearly encoded (i. e. unity gamma) the leftmost sliders would also act exactly like color compensation filters, making percentage-based changes in the intensity represented by each pixel. Unfortunately for the purposes of color correction, image files are normally stored in gamma-encoded form, using a gamma of 2.2 for PCs and 1.8 for Macs, instead of unity gamma. The result of this, mathematically, is that while the rightmost sliders of the Levels tool still have a color compensation filter action, the leftmost sliders do not – the percentage adjustment of intensity is not uniform and changes according to image brightness.

So, there are two choices regarding black point adjustments; either make small changes and hope for the best or convert the image to unity gamma before making the changes. While the second of these choices would seem to make the most sense, unity gamma images are difficult to judge, visually, on a standard display. If the required changes in the black point are not large, making them on the gamma encoded image will not cause major problems, especially if they are done first. If large changes are required, conversion to unity gamma might be worth the effort – except that if large changes are required the image probably has built-in problems that will require unusual corrections anyway.

The Levels black point picker tool operates the same as the other two picker tools; it can be used with a selected dark gray or other color rather than black. Again, if the black point picker is used, we prefer to adjust the leftmost R, G, and B sliders back by the same amount so that the lowest of the three values is zero. After color balancing is completed, we use the Curves tool to make the dark tones as dark as desired.

Scanners normally produce a unity gamma image at greater than 8 Bits/Channel internally and hopefully make any color corrections in that mode before delivering a corrected image even if 8 Bits/Channel (but note that we always recommend using a 16 Bits/Channel image for preliminary adjustments if at all possible). Some scanners will deliver a raw image with unity gamma. With such images, the black point picker tool can be used more freely, with the image being adjusted to the system gamma only after all color corrections have been made. However, even with unity gamma images, Photoshop makes disproportionately large adjustments as the Shadows slider is moved to the right and large adjustments must be used with caution. For negative images we recommend using the Highlights sliders to make blackpoint adjustments, see
Color Balancing Color Negatives.

As these methods are original with us, you are welcome to use them in an article, a course, or a book but please credit C F Systems and

Privacy Policy and E-Mail
Go to C F Systems Home Page