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

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.


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.

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.
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 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 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.


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.


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).




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 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.


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.





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).



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.