Posterization

Article and Photography by Ron Bigelow

www.ronbigelow.com

Photoshop CS or Photoshop CS2 Used in this Tutorial

Have you ever come home from a shoot with that image that you are sure is going to be a winner? Its one of your best shots. You add the finishing touches and hit the print command. A few minutes later, out comes the print. Everything looks fantastic -- except the banding that runs across the sky. You try several different things in the editing program, but each new print continues to show the banding. At that point, that sinking feeling begins to set in as you realize that you may have lost one of your best shots. You are the victim of posterization.

Posterization

Figure 1: Posterization

Generally, colors in an image blend gradually from one color to the next. Is impossible for the human eye to tell where one color stops and the next one picks up. However, in some cases, the transition from one color to the next can actually be seen. This usually occurs in areas of little detail (e.g., featureless skies). The result is an image where bands appear to run across the image. This problem is known as posterization (also known as banding). An example of posterization is exhibited in Figure 1.

Posterization is highly undesirable. However, posterization can usually be prevented. For those cases where posterization has already occurred, it can usually be corrected if you know the proper technique. The purpose of this article is to cover the cause, prevention, and cure of posterization.

Posterization: Cause

The cause of posterization can be explained in one little sentence: too little information spread too far apart. The "information" refers to the tones contained in an image, and the "too far apart" refers to how far apart the tones are from each other. Figures 2 -- 5 illustrate this concept. Figure 2 (JPEG image) shows a color gradient from green to red. The gradient has a smooth transition of color across the gradient. Figure 3 shows the histogram of the image. The histogram shows no tonal gaps. In Figure 4 (JPEG image), the color gradient was subjected to some editing that caused posterization. The histogram in Figure 5 shows why the posterization occurred. This histogram shows that the tones are now spread far apart.

Figure 2: Colors with No Posterization before Editing (JPEG Image)
Figure 3: Histogram with No Tonal Gaps before Editing (JPEG Image)
Figure 4: Colors with Posterization after Editing (JPEG Image)
Figure 5: Histogram with Tonal Gaps after Editing (JPEG Image)
Figure 6: Shadow Tonal Values before and after Editing
In essence, posterization occurs when image editing causes too few tones to be spread too far apart. A typical example is when Curves is used to lighten the shadows in an image. Curves takes the original tones and runs the numerical values of the tones through a formula to create the numerical values for the new tones. Figure 6 shows an example of what happens for one set of shadow tones when modified by a particular Curves adjustment. It can easily be seen that the original tones increase only one unit from any tone to the adjacent tone. However, after Curves, the tones are spread farther apart. For example, with the original tones, going from a tone of one to a tone of two gave a one unit increase in tone. However, after editing, the tonal value of one became a value of seven, and the tonal value of two became a value of eleven. Now, the difference between these two tones has become four units. This was for a relatively mild Curves adjustment. A stronger adjustment would have spread the tones even farther apart.

Posterization Prevention

It is easier to put on a coat than to cure pneumonia. Similarly, it is easier to prevent posterization that to fix it after it has occurred. There are three ways to prevent posterization.

  1. Minimize image editing.

  2. Increase the number of tones through raw.

  3. Increase the number of tones through exposure.

Posterization Prevention #1: Minimize Image Editing

Now, this may not seem like the most brilliant or technical solution, but posterization can, sometimes, be significantly reduced or even eliminated by reducing the amount of image editing. For example, reducing the amount of Curves or Hue/Saturation used might help reduce or eliminate a posterization problem. Another possibility is to use a tool that doesn't spread the tones apart (e.g., use Brightness/Contrast instead of Curves). By reducing the amount of editing, or using a tool that does not spread the tones apart, the distance between the tones will be less and the posterization problem may disappear.

While a bit simplistic, and not possible with all images, this method may save the day for some images.

Posterization Prevention #2: Increase the Number of Tones Through Raw

One of the easiest ways to help reduce or eliminate posterization is to shoot images in raw. Raw has sixteen times more tones than JPEG. Therefore, the tones are much closer together than when the JPEG format is used. Thus, images that start as raw and are converted to high bit TIFF (or some other high bit format) for editing are much less likely to exhibit posterization.

The effect of having more tones can be seen by comparing Figures 2 -- 5 to Figures 7 -- 10. Looking back at Figure 2, we see an eight bit, JPEG image of a smooth color gradient that shows no tonal gaps in the associated histogram. However, after editing, the image exhibits heavy posterization (as shown in Figure 4) with large tonal gaps (as shown in Figure 5).

Figure 7 shows the exact same color gradient as that shown in Figure 2, except that this image is a sixteen bit image. The image has a smooth transition of color across the gradient. Figure 8 shows the histogram for the image. The histogram shows no tonal gaps. In Figure 9, the color gradient was subjected to the same editing done with Figure 4. This time, there is no posterization due to the larger number of closely spaced tones in this image, and the histogram in Figure 10 shows a lack of tonal gaps.

Please keep in mind that these color gradient images were created in Photoshop for illustration purpose. They were not created in a camera (e.g., Figures 7 and 9 were not created from raw images; however, they behave similarly to raw images that were converted to sixteen bit TIFF files). Thus, these images illustrate well the impact of having more tones.

Figure 7: Colors with No Posterization before Editing (16 Bit Image)
Figure 8: Histogram with No Tonal Gaps before Editing (16 Bit Image)
Figure 9: Colors with No Posterization after Editing (16 Bit Image)
Figure 10: Histogram with No Tonal Gaps after Editing (16 Bit Image)
So, a great defense against posterization is to shoot raw and convert the raw images to sixteen bit files for image editing.

Posterization Prevention #3: Increase the Number of Tones Through Exposure

Have you ever noticed that posterization tends to occur mostly in the darker parts of an image? There is a reason for that. The different tonal regions contain different numbers of tones. This is shown in Table 1. For a five stop dynamic range, JPEG image, there are 128 tones in the highlight tonal region (before application of tonal curves) but only sixteen tones in the shadow region (before application of tonal curves). Since the darker tonal regions have so few tones, posterization is a bigger problem in these regions.

Table 1: Distribution of Tonal Values for a Five Stop Dynamic Range Image (JPEG File) prior to Application of Tonal Curves
Light Level
Tonal Values
Notes
5 Stops
128
Highlights
4 Stops
64
Three quarter tones
3 Stops
32
Mid tones
2 Stops
16
Quarter tones
1 Stop
16
Shadows
However, there is a way to deal with the problem of the limited number of tones in the shadow areas. By increasing the exposure in the shadows by maximizing the exposure (see the article titled Digital Exposure) or by using multiple exposures (see the article titled Shadow/Highlight Detail -- Part IV) the number of tones is increased in the shadows. For example, as shown in Table 1, exposing in the usual way, the shadows would get one stop of exposure and would contain a mere sixteen tones. If the maximizing the exposure or multiple exposure technique was used to give the shadows one extra stop of exposure, the shadows would have two stops of exposure. The first stop of light would generate sixteen tones, and the second stop of light would generate another sixteen tones. The shadows would now contain thirty-two tones, rather than just sixteen. The addition of the extra tones would reduce the tendency for posterization in the shadows. While this may make the shadows lighter than desired, the brightness of the shadows can be adjusted in the raw converter or Photoshop to bring the shadows back to the desired brightness level.

Fixing Posterization

Figure 11: Image with Dark Tones
So, you've got an image that you shot before you read this article (or you ignored my advice). You love the image, but it has posterization. Can the posterization be fixed? Absolutely. Best of all, the fix is quick, easy, and free!

Figure 11 shows one of my favorite images. I was excited about this image from the time that I pressed the shutter button. However, when I made my first print, I was greatly disappointed when I saw bands running across the sky (you can not see the banding in this small, web image). Happily, the following technique saved the image.

The posterization issue is resolved by adding something that, under normal conditions, everyone tries to get rid of: noise. The noise is added in very small amounts to only the areas that show posterization (the sky in this image). The noise breaks up the edges of the bands so that the eye can no longer detect the edge (kind of like how camouflage breaks up the outline of a human figure so that it is not discernable). On the other hand, the noise is added in such small amounts that it is not readily noticeable at the normal viewing distances for prints. Furthermore, since posterization is most noticeable in dark areas that have little detail, the noise is being added to areas where there is not much detail with which the noise can interfere. This is seen in Figure 11. The noise will be added to the sky where it will not hinder any significant detail.

One important point is that the noise should be added after all editing has been completed and the image has been interpolated to its final size but before the final sharpening has been performed.
Figure 12: Layers Palette
The technique starts off with the Layers Palette. Figure 12 shows the layers palette for this image. A new layer is added by choosing Layer/New/Layer. This will bring up the New Layer dialog box (see Figure 13). The name of the layer should be changed to Noise. The Use Previous Layer to Create Clipping Mask option should be unchecked. The color should be set to None, the mode to Normal, and the Opacity to 100%. Clicking OK will create the new layer.
Figure 13: New Layer Dialog Box
Figure 14: Layers Palette with the Noise Layer
The new layer must be moved to the top of the Layers Palette (if not already there). Figure 14 shows the Layers palette with the Noise layer.
Figure 15: Layers Palette with the Visible Layers Merged into the Noise Layer
For the next step, the Noise layer must be selected. The effects of the layers below the Noise layer are now merged into the Noise layer by holding down the Alt key (Option key for a Mac) while choosing Layer/Merge Visible. The Noise layer is now a duplicate of everything below it (the layer can be clicked on and off without affecting what the image looks like). The Layers palette at this stage is shown in Figure 15.
Figure 16: Add Noise Dialog Box
With the Noise layer selected, the noise is added by choosing Filter/Noise/Add Noise. The Add Noise dialog box appears as shown in Figure 16. There are three settings on this dialog box. Amount determines how much noise is added. For the purpose of removing posterization, only a small amount needs to be added. For a 13 x 19 print, 3% or 4% usually works well. The Distribution control sets the type of noise that is added and should be set to Gaussian. Finally, the Monochromatic box should be checked. Checking this box makes sure that the noise that is added is only tonal. In other words, no color noise will be added. Clicking the OK button will add the noise to the Noise layer.
Figure 17: Layers Palette with Mask Added to the Noise Layer
Right now, noise has been added to the entire image. It is necessary to add a mask to the Noise layer so that only the areas where banding occurs are affected by the noise (it is assumed that the reader knows how to create masks as that topic is beyond the scope of this article). For this image, everything but the sky was masked. Figure 17 shows the Layers palette with a mask added to the Noise layer.
Figure 18: Layers Palette with Sharpening Layer
The last step that needs to be performed is the sharpening. Any sharpening technique can be used. However, it is generally necessary to protect the areas were the noise was added from the sharpening (otherwise, the noise will be sharpened and will stand out). This can be done by adding a mask to the sharpening layer. Figure 18 shows the final Layers palette with the sharpening layer and mask.

Summary

Prevention is always better than a cure. By shooting in raw and maximizing the exposure or shooting multiple exposures, a photographer can greatly reduce problems with posterization. For those cases where posterization can not be prevented, this noise technique can save an otherwise great image.

Articles