Levels in Photoshop -- Part I

Article and Photography by Ron Bigelow

www.ronbigelow.com

Photoshop CS or Photoshop CS2 Used in this Tutorial

Levels is one of the most fundamental of the Photoshop tools. It is usually among the first tools taught to novice photographers when they begin learning image editing. It is a fairly straightforward tool. However, not everyone that uses Levels is aware if its full potential. Thus, the purpose of this article is to cover Levels and its capabilities.

Capabilities

Levels is commonly used for five tasks:

  1. Setting the shadow and highlight values.
  2. Setting the midtone contrast.
  3. Performing color correction.
  4. Setting custom white balance.
  5. Preparing for printing.

When it comes to setting the shadow values, highlight values, and midtone contrast, there several ways that Levels can be used:

  1. Manual: RGB Channel.
    1. Info palette.
    2. Eyeball.
  2. Manual: Eyedroppers.
  3. Manual: Individual Color Channels.
  4. Automatic:
    1. Enhance Monochromatic Contrast.
    2. Enhance per Channel Contrast.
    3. Find Dark and Light Colors

Background

Figure 1: Histogram

In essence, Levels is a tool that is used to control contrast and to adjust tones/colors. Therefore, Levels is intimately tied to the histogram. So much so that a histogram is displayed in the middle of the tool. In order to understand Levels, it is necessary to understand histograms.

Histograms display tonal or color distributions (see Figure 1). There are a total of 256 tones/colors in the histogram. The darkest tone/color is assigned a value of zero. The lightest tone/color is assigned a value of 255. The horizontal axis displays these tones/colors from the darkest on the left to the lightest on the right. The vertical axis shows the number of pixels that have each tone/color. In Figure 1, for example, it can be seen that a large number of pixels are in the middle of the distribution.

Figure 2: Histogram
Figure 2 is the same histogram as Figure 1 with a couple of arrows added. This histogram shows a problem with the image. The area to the left of arrow #1 has few, if any, pixels. Since this end of the histogram displays the darker pixels, the lack of pixels at this end shows that there are few true blacks or very dark pixels in this image. The area to the right of arrow #2 also has few, if any, pixels. Since this end of the histogram displays the lighter pixels, the lack of pixels at this end shows that there are few true whites or very light pixels in this image. What this means is that the image lacks contrast.
Figure 3: Image before Levels Adjustment
Figure 3 shows the image from which the histograms in Figures 1 and 2 came. This image clearly shows a lack of contrast. Instead, it has a dull, flat look. This is the exact type of problem for which levels was designed.

Definitions

In order to apply Levels effectively, a few terms need to be understood:

Shadow Values: The shadow values are the three color values (i.e., red, green, and blue) of the darkest point in an image where detail still exists. Any points darker than the shadow values have no image detail and show as solid black.

Black Point: The tonal point at which solid black occurs. Tonally speaking, the black point occurs just below the shadow values.

Highlight Values: The highlight values are the three color values (i.e., red, green, and blue) of the lightest point in an image where detail still exists. Any points lighter than the highlight values have no image detail and show as solid white.

White Point: The tonal point at which solid white occurs. Tonally speaking, the white point occurs just above the highlight values.

Gamma: In this context, gamma refers to the contrast of the image. The higher the gamma, the higher the contrast.

The Levels Dialog Box

Figure 4: Levels Dialog Box

Figure 4 shows the Levels dialog box. At the top of the dialog box is the Channel list. This allows the photographer to choose whether to edit the RGB channel or one of the three, individual, color channels.

The Input Levels show the values for three important items. The left value shows the tonal value where the black point is set (i.e., if a tone of 5 is shown in this box, the tone of 5 will be changed to black), the middle value indicates the gamma (e.g., contrast) for the midtones, and the right value shows the tonal value where the white point is set (i.e., if a tone of 250 is shown in this box, the tone of 250 will be changed to white). The middle of the dialog box shows the histogram for the image. Directly below the histogram are three sliders. The left slider is the Black Input Slider and is used to set the black point or shadow values (depending on how it is used; we will use it to set the shadow values). The middle slider is the Gamma Input Slider and is used to set the contrast of the midtones. The right slider is the White Input Slider and is used to set the white point or highlight values (depending on how it is used; we will use it to set the highlight values). Moving the black and White Input Sliders inward increases the contrast of the image, but it can also clip tones at the ends of the histogram. As these three sliders are moved, the values in the corresponding Input Levels boxes change.

The Output Levels set the darkest and lightest tones in an image. The Output Levels allow a photographer to compress an image into a smaller tonal range (e.g., 10 -- 245) than the 0 -- 255 range that is normally used. The left value sets the darkest tone, and the right value sets the lightest tone. Directly below the Output Levels are two sliders. The left slider is the Black Output Slider and is used to set the darkest tone in the image. The right slider is the White Output Slider and is used to set the lightest tone in the image. The Output Levels and the associated sliders are generally used to target an image for a particular output device (e.g., if the darkest tone a printer can print is 5, the black output slider can be used to adjust the image for that printer).

In the lower right corner of the dialog box are three Eyedroppers. The left Eyedropper is the Black Eyedropper and is used to set the black point or shadow values (depending on how it is configured; we will use it to set the shadow values). The right Eyedropper is the White Eyedropper and is used to set the white point or highlight values (depending on how it is configured; we will use it to set the highlight values). These Eyedroppers are an alternative to using the Black and White Input Sliders. The middle Eyedropper is the Gray Eyedropper and is used to set neutral gray in the image.

On the right side of the dialog box is a set of buttons. These buttons allow for the saving and loading of Levels configurations as well as the use and settings of Auto Levels.

Shadow Values, Highlight Values, and Midtone Contrast: Info Palette Approach

One of the most frequent uses of Levels is to alter the contrast in an image. Probably, the most common way to do this is to make manual adjustments in the RGB channel. This can be done in two ways: the eyeball approach and the Info palette approach. The Info palette approach is more exact than the eyeball approach. It also allows for better tracking of how one adjustment affects the tonal values set by previous adjustments. The drawback is that the Info palette approach takes more time and effort.

In my articles, I generally like to start with the simple and build up to the more complex. However, in this article, we are going to start with the more complex Info palette approach because this approach far better illustrates what is happening as different adjustments are made in Levels, and allows those readers, who so desire, to develop a deeper understanding of the workings of Levels.

Figure 5: Info Palette
With this approach, the first two tasks that need to be performed are to set the shadow values and the highlight values. However, a problem immediately occurs. How do we know where the darkest and lightest points, that hold detail, are located in an image? The human eye is simply not a good judge of such things. To resolve this issue, the Info palette is used. The Info palette shows the colors of any chosen point. The Info palette is launched by choosing Window/Info. The options for the Info palette are set by clicking on the triangle in the upper right hand corner of the palette and choosing Palette Options (see Figure 5). The Palette Options dialog box appears as shown in Figure 6. Both the First Color Readout Mode and the Second Color Readout Mode should be set to Actual Color. Clicking the OK button closes the dialog box.
Figure 6: Palette Options Dialog Box
Figure 7: Color Sampler
When the lightest and darkest areas that contain detail have been identified, they will be targeted. For this, the Color Sampler will be used. The Color Sampler is selected from the Tools palette as shown in Figure 7. The Color Sampler will allow color samplers to be placed on the image. The color values at the color samplers can then be read in the Info palette. Before placing the color samplers, it is necessary to set the sample size of the Color Sampler. This is done by clicking on the Sample Size pop-up in the upper left hand corner of the screen. For this purpose, it is best to select the 3 by 3 Average (see Figure 8).
Figure 8: Sample Size Pop-Up
Figure 9: New Layer Dialog Box
We are now ready to start using Levels. With the image open in Photoshop, Levels is launched by choosing Layer/New Adjustment Layer/Levels. The New Layer dialog box appears as shown in Figure 9. The Use Previous Layer to Create Clipping Mask is left unchecked. The Color is set to None, the Mode to Normal, and the Opacity to 100%. Clicking the OK button closes the dialog box and brings up the Levels dialog box as show in Figure 10.
Figure 10: Levels Dialog Box
The shadow values are set first. While holding down the Alt key, the Black Input Slider is moved to the right. As soon as the slider is clicked, the image will turn white. As the slider is moved to the right, parts of the image will start to change colors. The parts of the image that change color are being clipped. The first parts of the image to change color contain the darkest tones in the image. These are the areas that will be used to set the shadow values. Figure 11 shows the Levels Dialogue Box at the point where some of the image has just started to turn black. Figure 12 shows the how the image is displayed with the Alt key held down.
Figure 11: Levels with the Black Input Slider Moved to the Right
Figure 12: Image with the Black Input Slider Moved to the Right While Holding Down the Alt Key
Figure 13: Image with Color Sampler Added at Shadows

Figure 12 shows that the darkest tones are just along the right river bank.

After releasing the Alt key, the Color Sampler is now moved around the dark areas of the river bank where the dark tones have been identified (the curser turns into the Color Sampler as it is moved over the image). As the Color Sampler is moved around, the Info palette indicates the tonal values (for the three color channels) of the location directly below the Color Sampler. For the setting of the shadow values, it is desired to find a position that has very low tonal values but still holds detail (an area has detail if the values in the Info pallet change as the Color Sampler is moved around). It is also a good idea for the position to be fairly neutral (i.e., the three tonal values are approximately equal). A position on the river band with values of 12, 12, 12 was found. While holding down the Shift key, the Color Sampler is clicked at this point. A color sampler is added to the image (see Figure 13). Now that the position of the shadow values has been selected, the Black Input Slider is moved back to the far left.

The value of the color sampler is shown on the Info palette (see Figure 14). The first row of numbers shows the original values of the colors at color sampler #1. The second row shows the current value of the colors at the color sampler. Since no image editing has yet been performed, the two rows are the same. As edits are made, the values in the second row will change.

Figure 14: Info palette after Shadow Color Sampler was Added
The highlight values are set next. While holding down the Alt key, the White Input Slider is moved to the left. As soon as the slider is clicked, the image will turn black. As the slider is moved to the left, parts of the image will start to change colors. The parts of the image that change color are being clipped. The first parts of the image to change color contain the lightest tones in the image. These are the areas that will be used to set the highlight values. Figure 15 shows the Levels Dialogue Box at the point where some of the image has just started to turn white. Figure 16 shows the how the image is displayed with the Alt key held down.
Figure 15: Levels with the White Input Slider Moved to the Left
Figure 16: Image with the White Input Slider Moved to the Left While Holding Down the Alt Key
Figure 17: Image with Color Sampler Added at Highlights

Figure 16 shows that the lightest tones are just along the sky and on the sign on the bridge.

The Color Sampler is now moved around the sky where light tones have been identified. For the positioning of the highlight values, it is desired to find a position that has very high tonal values but still holds detail. It is also a good idea for the position to be fairly neutral. The sky was checked, but the Info palette showed color values of 255, 255, 255 everywhere in the sky. In other words, the sky is pure white with no detail. Therefore, it is not usable for the highlight values. A position on the sign that is attached to the bridge shows values of 224, 220, 224. While holding down the Shift key, the Color Sampler is clicked at this point. A color sampler is added to the image (see Figure 17). Now that the position of the highlight values has been selected, the White Input Slider is moved back to the far right.

The value of this color sampler is shown on the Info palette (see Figure 18).
Figure 18: Info Palette after Highlight Color Sampler was Added
Figure 19: Levels with the Shadow Values Set

It is now time to set the shadow and highlight values. For the shadow values, the color values should be set between about 2 and 8. The lower the value, the darker the shadows will be. To set the shadow values, the Black Input Slider is moved to the right until the desired values are indicated for the first color sampler on the Info palette.

With the Black Input Slider moved to the position shown in Figure 19, the Info palette shows that the original shadow values of 12, 12, 12 are now values of 2, 2, 2 (see Figure 20). Thus, the shadows have been darkened.

Figure 20: Info Palette with the Shadow Values Set
Figure 21: Levels with the Highlight Values Set

For the highlight values, the color values should be set between about 245 and 254. The higher the value, the lighter the highlights will be. To set the highlight values, the White Input Slider is moved to the left until the desired values are indicated for the second color sampler on the Info palette.

With the White Input Slider moved to the position shown in Figure 21, the Info palette shows that the original highlight values of 224, 220, 224 are now values of 255, 254, 255 (I made a judgment call on this one and set the highlight values a bit on the high side). Thus, the highlights have been lightened (see Figure 22).

Figure 22: Info Palette with the Highlight Values Set
Figures 23 and 24 show the original image and the image after the shadow and highlight values were set.
Figure 23: Original Image
Figure 24: Image after the Shadow and Highlight Values were Set
Figure 25: Levels with the Final Settings

Already, the image has begun to look better.

The last step with Levels is to adjust the midtone contrast by using the Gamma Input Slider. Moving the Gamma Input Slider to the right increases contrast. Moving the Gamma Input Slider to the left decreases contrast.

A Gamma Input Slider setting of 0.87 adds some additional contrast to this image. Figure 25 shows Levels with the final set of shadow, highlight, and gamma settings.

Figure 26: Info Palette with the Final Settings

Figure 26 shows the Info palette after all of the slider adjustments have been made. It can be seen that the Gamma Input Slider adjustment slightly changed the values for the shadow and highlight values. These points could be readjusted with the appropriate sliders. However, for this image, the changes are slight, so no further adjustments will be made. Clicking the OK button closes Levels.

Figures 27 and 28 show the original image and the image after all the adjustments were finalized.

Figure 27: Original Image
Figure 28: Image after All Adjustments were Made

Shadow Values, Highlight Values, and Midtone Contrast: Eyeball Approach

The eyeball method to setting the shadow values, highlight values, and midtone contrast is a faster approach.

To set the shadow values, the Black Input Slider is moved to the right while holding down the Alt Key. Initially, the image will turn white. When the image begins to show detail getting clipped, the slider should be moved back a bit until only the pure blacks (with no detail) are left visible. Figure 29 shows the Levels Dialogue Box with the Black Input Slider at the selected point. Figure 30 shows the how the image is displayed with the Alt key held down.

Figure 29: Levels with the Black Input Slider Moved to the Right
Figure 30: Image with the Black Input Slider Moved to the Right While Holding Down the Alt Key
To set the highlight values, the White Input Slider is moved to the left while holding down the Alt Key. Initially, the image will turn black. When the image begins to show detail getting clipped, the slider should be moved back a bit until only the pure whites (with no detail) are left visible. Figure 31 shows the Levels Dialogue Box with the White Input Slider at the selected point. Figure 32 shows the how the image is displayed with the Alt key held down.
Figure 31: Levels with the White Input Slider Moved to the Left
Figure 32: Image with the White Input Slider Moved to the Left While Holding Down the Alt Key
Figure 33 Levels with the Final Settings

The midtone contrast is set the same way as was done with the Info palette approach.

A Gamma Input Slider setting of 0.87 is about right for this image. Figure 33 shows Levels with the final set of shadow, highlight, and gamma settings. Clicking the OK button closes Levels.

Figures 34 - 36 allow you to compare the original image (Figure 34) with the images adjusted with the Info palette approach (Figure 35) and the eyeball approach (Figure 36).

Figure 34: Original Image
Figure 35: Image after Info Palette Approach
Figure 36: Image after Eyeball Approach
Those that have a high quality monitor might notice that the image done with the eyeball approach actually has colors with a bit more vibrancy. This might lead one to conclude that the eyeball approach is better. After all, it is quicker, easier, and can sometimes produce more vibrant colors. However, it is necessary to understand why the colors in the eyeball approach, sometimes, have a bit more punch. In the eyeball approach, the Info palette is not used. Therefore, it is not possible to know exactly what is happening in the shadows and highlights. As a result, in this particular image, the Black and White Input Sliders were moved inward more. This increased the contrast of the image over that of the image done with the Info palette approach. That gave the eyeballed image additional punch. However, this additional punch came at a cost. Anytime the eyeball approach is used, there is significant chance of moving the sliders inward too much and clipping the shadows and highlights. This causes a loss of detail in those areas. A better approach, that would have resulted in both vibrant colors and no loss of detail due to clipping, would have been to use the Info palette approach with Levels followed by additional contrast adjustments in Curves and saturation adjustments in Hue/Saturation.

Manual RGB Channel Approaches -- Considerations

When the manual RGB channel approaches are used, the shadow and highlight values will not always be neutral. In other words, the red, green, and blue values of the shadows values may not be equal. This is also true for the highlight values. In some cases, this may be an issue. On the other hand, setting the shadow and highlight values with one of the manual RGB channel approaches is not likely to cause unusual color shifts in an image, which can occur with other methods that force the shadow and highlight values to be neutral.

Articles

Levels -- Part II