Pages

Thursday, December 8, 2011

Exposure Compensation in Post Production Using Layer Blending Modes

Very often I hear people complain about what should be, apparently, a very easy thing to do: modifying the exposure of an image in post production. Truth is that if the adjustment you need is relatively small results are going to be satisfactory. Unfortunately, as long as you need to push the exposure adjustment a bit farther, results are often going to disappoint you.

Why?

Usually because of two factors:

  • Your image has not sufficient dynamic range to achieve the result you want (that's why you should shoot RAW if you can).
  • Because people don't clearly understand the physics of the human eye.


As far as it concerns the first factor, you cannot help but repeating it over and over again: you should shoot RAW if you can. Double check it. Even if you think you cannot. Some Canon point and shoots, for example, can be tweaked to shoot RAW.

As far as it concerns the second factor, here is yet another quick wrap up.

A Word of Warning: I'm a mathematician but if this is not a rigorous post. This is a quick tutorial for you to better understand some tools that are often misunderstood.

The Human Eye as a Sensor

As we stated many ways, one of the things that photographers often overlook is that the human eye is a logarithmic sensor. But what does it mean? It basically means that whenever the quantity of light doubles, whichever its frequency in the visible spectrum, you'll notice a comparable "brightness" improvement.

This also means that if you need to modify the exposure in post production, you cannot overlook this effect. You cannot just bump the channels up and down because luminance ratios must be preserved. If you don't, the dynamic range of your image will suffer and you'll end up with a flat, hazy image.

The Problem with the Brightness Tool

The problem with the Brightness tool is that, despite the name, it is not suitable to apply such a modification. It depends on the tool you're using but as far as it concerns the software most commonly used (Photoshop and The Gimp), a brightness adjustment does not what you think it does.

Roughly speaking, the brightness adjustment just adds a correction to the pixel values:

n = o + d

where o is the old value and d is the selected brightness adjustment. It might look right, doesn't it? It does shifts the histogram left or right (depending on the sign of d). But it does not preserve ratios and, as such, it is not the tool you need to tweak an image exposure preserving its dynamic range.

Here's what happens trying to fix an artificially underexposed TIFF image using just the Brightness tool (in this post I'll use The Gimp):

Original Underexposed Image

Brightness raised to 100


This test image is badly underexposed but the detrimental effect introduced by the Brightness adjustment on an image dynamic ratio won't ever be avoided.

If you like Mathematics, try to bring d to infinity and think at what happens to the (absolute value of the) ratio between two pixels value: it just goes down to 1. That's why your images will soon start to lose contrast.

Many people will then try to fix the contrast but that won't work, either.

What Can Be Done?

Preserving the ratios! To preserve the ratio, you need to correct a pixel values using a multiplier. That's what the Multiply and Screen blending modes are made for:

  • If you need to lower the exposure of your image, you can blend a layer with a copy of itself using the Multiply blending mode.
  • If you need to raise the exposure of your image, you can blend a layer with a copy of itself using the Screen blending mode.


What do these blending modes do?

Basically, they're effect is:

  • Screen lightens a pixel in the lower layer proportionally to the "brightness" of the corresponding pixel in the upper layer.
  • Multiply darkens a pixel in the lower layer proportionally to the "darkness" of the corresponding pixel in the upper layer.

What happens if you blend a layer with a copy of itself using these blending modes? It applies the very effect we were looking for!

Again, if you like Mathematics, just think about the definition of the exponential function. What happens when you're modeling a phenomenon whose variation (derivative) depends solely on its intensity? Refine this concept: is there any function whose derivative in a point x is only a function of the value of the original function in the point x? Yes: the exponential function.

We're applying an exponential transformation on a matrix of points that will be fed in a logarithmic sensor (the human eye). Just what we were looking for.

Here's what happens when we screen the test image we used before with itself (twice):

Screen Blending Mode

This is a much better result indeed.

If you're new to layers and blending modes, well, it's time you get serious about them. Here's a screenshot of The Gimp layer palette of the previous image:

The Gimp - Layer Palette

Conclusion

The Brightness and Contrast tools are often misused and it's important you understand what's going on under the hood. If you need to apply an exposure compensation, they're not the right tools. Instead, take some time to learn about layer blending modes. The Multiply and the Screen blending modes are just the beginning. Here are some additional tips:

  • You can mix and match them to achieve more sophisticated results and you can fine tune the effect tweaking the layer transparency.
  • If screening or multiplying two layers is too much compensation for your image, just make the layer a bit more transparent.
  • If you're looking for a way to raise the overall contrast of an image, try to screen and multiply it.
  • You may also want to take a look to the Overlay blending mode, which is a mix between the Screen and the Multiply (it screens dark colors and multiplies bright ones).


If you want to help me keep on writing this blog, buy your Adobe Photoshop licenses at the best price on Amazon using the links below.

No comments:

Post a Comment