/**********************************************************************

This article was created on Saturday the 15th of July 2006 at 11:29 AM

This article was updated on Sunday the 16th of July 2006 at 19:18 PM

This article has been read 75000 times since it’s posting this morning at 11:29 AM

…100000 times @ 17:51 PM

…114000 times @ 18:20 PM

…141000 times @ 19:19 PM

…152000 times @ 19:39 PM

…167000 times @ 20:19 PM

It has made this blog #2 of WordPress growing blogs, it is the #3 post on WordPress right now and The Memoirs are #4 blog on WordPress.

This post is #6 on Reddit.com and #7 on del.icio.us‘s most popular saves for today. Also, diggdot.us and Popurls, sites that aggregate news from sites such as Reddit, have generated traffic towards this post. If you liked this post, please reddit through Reddit.com. I am currently writing an analysis on this whole phenomenon and will continue posting articles on HDR and photography.

Any comments, sponsors and inquiries:

memoirs [dot] on [dot] a [dot] rainy [dot] day [at] gmail [dot] com

This article is the first in a series of articles on HDR photography

**********************************************************************/

In this Saturday morning post, I explain HDR photography with the help of some articles. This post includes step by step ways to create your own HDR images. Be advised that they can be quite hard for beginners to get interesting results. But where there is a will, there is a way! And by experimenting, you will get some good pictures. Also, remember that to see the end result, you have to get through some initial steps.



I have received some questions about certain photographs, so I’ve decided to include three articles that explains HDR photography in detail. I had added this to the comments, but I felt this deserved to be included in a post by its own. I have found a few different articles to explain this to everyone. The first one dwelves in the theory behind. The second one is an easy way to to HDR and the third one goes in to more detail on the process of HDR photography. The source of the first article is from cybergrain. The second article is from HDR 101. And the third is from Cambridgeincolour.This post also include step by step ways to create your own HDR images.

If you want anymore information, research the sites that I have mentioned or ask questions in the HDR Pool on flickr.

Update @ 17:54 EST, Saturday the 15th of July 2006

This is by no means the only pool on flickr for this type of photography. Check out here for more groups.

To begin using HDR photography, you need a few simple things.

A digital camera, preferably a DSLR but a good point and shoot will do the job. Remember, you need to be able to change the shutter speed manually. The focus can stay auto but if you can set it on manual do so A tripod; to function correctly, HDR needs to take different pictures of the same scene. If you do not want any motion flow, take pictures of stationary objects. Latest edition of Photoshop Photomatix, available free here through their new beta release for Windows. A Mac version is also available on their website. For simple step by step instructions, scroll down to the second article and follow the steps.

* * * * *

The following article is by Jon Meyer from one of his articles on HDR Photography. You can find the source article here. Due to the interest, he has updated his article as of Sunday, the 16th of July. I have made the changes accordingly. Thanks Jon Meyer!

* * * * * *

The Future of Digital Imaging – High Dynamic Range Photography

Introduction

Today’s digital cameras match or slightly exceed the performance of silver halide film. Computer graphics has achieved the goal of photorealism. Now the goal is to go beyond simply matching paper and silver halide – to create display technologies which can present any visual stimuli our eyes are capable of seeing.

One area of rapid development is in dynamic range. A new crop of technologies using High Dynamic Range imaging (HDR or HDRI) aim to extend the dynamic range of digital imaging technologies way beyond traditional media.

In this article, I’ll look at recent advances in the field of high dynamic range imaging. I will cover the basic concepts of dynamic range, and talk about new HDR technologies.

The Problem

Here’s the problem in a nutshell:

Real-world scenes contain light ranges that exceed a 50,000:1 dynamic range.

For over a thousand years, media has been limited to around a 300:1 dynamic range.

So you have a mapping issue: how do you represent light values in a scene using a much more limited set of light values for a particular media?

If you are not careful, you end up with results like this:

You can see the chair but nothing out of the window.

Old Solutions

Master painters were very clever about mapping scene intensities to canvas. They used a large number of tricks. Look at El Greco’s La Agoria en el Jardin from 1590:

El Greco used saturated colors of opposing hues to increase the apparent dynamic range of the scene. He also painted black or white lines around the edges of contours. Our eyes determine contrast locally, so increasing the contrast at local edges increases the overall perceived contrast of the scene.

(Generally, the phrase “dynamic range” in imaging refers to the measured ratio between high and low extremes in a set of intensity values. The word “contrast” is often used interchangeably with dynamic range, though I prefer to use “contrast” to refer to the perceived contrast of a scene, which may be different from the measured dynamic range. For example, El Greco’s edge contours increase perceived contrast but don’t change the actual dynamic range of canvas).

Here is an example from Monet. The red sun in his famous Impressions at Sunrise really leaps off the canvas (maybe not on your web browser!). The sun is actually the same brightness value as the surrounding clouds. However, since the sun is a saturated red placed over a saturated blue cloud, it creates a color vibration, and the sun looks much brighter than it is:

Check out webexhibits way-cool Flash illustration of this.

Dynamic Range in Photography

Photography involves a capture device (the camera), a storage medium (e.g. film), and a display or output device (e.g. paper).

The dynamic range of each stage (capture, storage and output) plays a crucial role in the quality of the results. In general, technologies with greater dynamic range produce more realistic results. But photography is a compound process, and the dynamic range of each stage must be considered. When the dynamic range of the source scene is too great for any one stage of the process, something must be sacrified: you must either give up detail in the shadows or the highlights. Photographers have to know and work withing the limitations of their camera, storage and output devices.

W. Eugene Smith spent five days in the darkroom until he came up with a print of Albert Schweitzer that he was happy with:

Smith was dealing with the issue that silver halide negatives have a greater dynamic range than photographic paper – so he had to “dodge and burn” different areas of the image to get a result where both the lamp and sitter are visible.

Perhaps the greatest master of dynamic range in photography was Ansel Adams. He was the first to systematically measure the sensitivity range of all of the equipment he used. His “zone system” let him predict precisely what details he could capture on film and paper, so he could make decisions before pressing the shutter:

Color Photography

Color negative films have less dynamic range (or “latitude”) than black and white films. My understanding is that the multiple layers and dies in color film result in reduced sensitivity. The first color films had very poor latitude, so film manufacturers added more layers – each color layer was split in two, a high-sensitivity and a low-sensitivity layer, using different crystal formations:

(I’m not an expert, but maybe color positive film doesn’t use this trick, hence the difference in latitude between positive and negative film?)

One way to get really great dynamic range with color film photography is to use black-and-white film together with color filters. You have to take three exposures on separate sheets of black and white film: one with a red filter, one with a green, and one with a blue – and then composite the three images together. If you use glass plate negatives, you end up with images that have incredible colors and resolution. See below:

The most amazing thing about this image is that it was taken in around 1915 by Prokudin Gorskii. While it is true that this image was digitally enhanced in Photoshop, in my own experiments with a 4×5 and red/green/blue filters I achieved an extended non-kodachrome tonal scale.

The Next Horizon: Digital HDR

Over the next decade, the imaging industry will inevitably transition to high dynamic range (HDR) imaging, creating devices that provide a latitude range far greater than traditional silver halide film. This change will affect all aspects of image making. Each of the systems in the image workflow will be modified, including capture, storage, editing and output.

Let’s look at each of these workflow stages in turn.

Capture

Today’s cameras have ample resolution. So the next area of product differentiation for camera manufacturers will be the quality of the pixels, rather than the number of pixels. This shift is starting to happen already.

For example, Fuji’s SuperCCD S3 Pro camera has a chip with high and low sensitivity sensors per pixel location to increase dynamic range (the same trick as used in color film to achieve broader latitude).

Although the resulting chip has lower overall resolution, it captures greater dynamic range. This tradeoff of resolution for dynamic range is the beginning of an important trend.

A second alternative is to merge multiple images to increase dynamic range. Paul Debevec at SIGGRAPH 97 showed how to take multiple photographs at different exposures and merge them together to create a single high-dynamic range image. This technique is now incorporated in products such as Photogenics and Photoshop. For now, the technique works best if the camera is mounted on a tripod. But researchers have already built HDR image “stitchers” which merge multiple images and automatically account for camera motion between snaps.

For most consumers, “HDR” will simply mean that the camera records more details in shadows and in highlights. Just as RAW images extended the detail held in digital images, HDR will further increase the available tonal range.

Consumers will benefit from the true point-and-shoot ability that broader latitude offers, because HDR cameras will produce usable images from a much wider range of lighting situations.

Eventually point-and-shoot cameras will lose their built-in flash. Anyone who uses a camera with a cheap flash soon learns that the pictures generally look better if you turn the flash off. Sensors are becoming more sensitive, cameras are getting smaller, and light metering is getting smarter. Add three or four stops of dynamic range, and the flash becomes a creative ad-on rather than a requirement.

Professional photographers will also benefit from HDR. With HDR technologies, photographers can really push the creative envelope, exploring the extremes of high-key and low-key effects.

Professional cameras will offer a multitude of HDR image-taking modes. For example, they will automatically blend multiple images taken with different exposures, with and without flash, possibly using multiple light sources, to produce a single and extremely maliable master image.

Storage

All image file formats have range limitations. Formats such as JPEG and GIF provide eight bits per color channel (often referred to as 24 bit color). Using 8 bits, you can represent 256 different intensities per channel. Most 8 bit formats use a “perceptual” mapping, meaning that they use a gamma (exponential) curve rather than a linear map of intensities. See Human vision and tonal levels or the venerable Gamma FAQ for an explanation of this. While JPEG and GIF are great for moderate dynamic range images, banding becomes apparent if you edit the image extensively, and the formats cannot store high-dynamic-range scenes.

Newer formats including JPEG2000, RAW and PNG offer up to 16 bits per color channel, which is plenty for most purposes. However, there is no support for “underage” or “overage” – these image formats state that “0” should be mapped to the darkest black of the display, and “65536” (or the equivalent) should be mapped to the whitest white. If you want to represent images that contain brightnesses beyond what your monitor can currently display (e.g. as produced by HDRShop), you need to look elsewhere.

The most exciting HDR image format today is OpenEXR, developed by Industrial Light & Magic.

I say this partly because their documentation includes photos from Star Wars (see above). But it also supports both 16-bit and 32-bit float representations, lossy and lossless codecs, and has a great definition for underage and overage.

Other examples of High Dynamic Range formats include SGI’s TIFF LogLuv format, Floating Point TIFF format, Radiance’s RGBE format, and Portable Float Maps (PFMs).

HDR image formats are especially significant for archival and stock uses, since they store data with enough precision to record what we can see, rather than what our displays can show.

There are a range of proprietary formats that offer medium or high dynamic range. The various RAW formats support whatever dynamic range the underlying device associated with the RAW file uses. Personally, I am not a fan of RAW formats for long term image stoage, since they are too device and vendor specific. However, that’s a whole other debate.

I don’t yet know if OpenEXR will become a consumer standard, or if it will remain a file format used only by Hollywood. Microsoft, Apple, Adobe, Canon and others will no doubt have a big hand in shaping that decision.

Editing

Of all imaging tasks, editing is the one that demands the highest dynamic range. Editing operations need high precision to avoid aliasing artifacts such as banding and jaggies.

Audio professionals know this. Editing tools like ProTools already use 48 bits per sample internally, even though the common CD output format only supports 16. Why should we image makers accept anything less?

Recently, Adobe announced supports for 32-bit-per-channel HDR images in Photoshop CS2, a great step forward.

Idruna Software is another company doing interesting HDR software. I played with their PhotogenicsHDR when it first came out, but I found it a little hard to use. Perhaps the newest PocketPC version is different…

Photoshop users are familiar with the issues of low dynamic range today. With 8 bit channels, if you brighten an image, information is lost irretrievably: darkening the image after brightening does not restore the original appearance. Instead, all of the highlights appear flat and washed out. To avoid this problem, you must work in a carefully planned workflow.

With a true HDR tool, if you brighten an image and then darken it, you should see something very close to the original image. True HDR editing tools will enable image workers to follow a much more flexible and simplified workflow, using fewer adjustment layers, with fewer aliasing artifacts. I expect HDR software will lead to increases in productivity and greater expressiveness.

It will take the imaging software industry some time to retool and retrain. There are plenty of unsolved issues.

With HDR, for example, you run into the issue of representing brightness values present in the image but beyond what your current monitor can show. Do you clamp to the monitor’s gamut, show zembra stripes, map the colors some other way?

Another issue is how to create graphical user interfaces for HDR editing. Many designers are familiar with the RGB 0-255 color values, and can type in RGB color numbers directly using this system. e.g. 128,128,128 is a mid gray. But what happens when intensities go from 0 to several million? Where is mid gray? And how do you represent that in a graphical interface? If the tonal range goes from 0 to something close to the brightness of the sun, where is “white” on that scale? Do you mean monitor white, paper white, 3200k white, 5600k white …?

A third unsolved issue is image size: If each channel of an image is 32 instead of 8 bits, the image becomes four times larger. Switching to HDR therefore makes a 100mb image take up 400mb. Not surprisingly, editing operations take about four times longer. Software will need to become smarter about scheduling work. Live Picture, an early image compositing tool, did a good job of this, but is no longer available. I expect to see a revival of these techniques as people grapple with 10GB images.

Tone Mapping

Most LCD/CRT displays (and of course printed paper) have low dynamic range.

So if you want to output an HDR image on paper or on a display, you must somehow convert the wide intensity range in the image to the lower range supported by the display. This process is called tone mapping.

One old tone-mapping method is the manual dodge-and-burn technique familiar to photographers – where you manually select different tonal ranges for different regions of the image, using a dodging or a burning tool. HDR software will of course support manual dodge and burn.

Another solution is to use an automated tone mapping filter to reduce the dynamic range of an HDR image. There are already several filters to choose from.

The left image above shows what you get if you display Paul Debevec’s HDR photo of Stanford Memorial Church using a very basic tone mapping technique (simply clamping to the nearest available color on the monitor). Some areas of the image are “blown out”, and the shadow areas are muddy and lack detail.

The right image show’s Fattal, Lischinkski, and Werman’s tone mapping algorithm, which uses a more sophisticated adaptive approach – you see more details in the shadows and the highlights (look at the stained glass windows), though the image also has a somewhat “flat” or “computerish” quality.

Tone mapping is a hot area of research in computer graphics. As with HDR file formats, there is currently no clear winner. Several techniques are listed in the resource section. I expect the major companies to each champion their own tone-mapping technologies in service bureaus and print finishing.

Output

Over the past decade, display companies have steadily improved the dynamic range of LCD and DLP displays. Today many digital displays have a 2000:1 dynamic range, unheard of ten years ago. This trend of increasing dynamic range will continue.

A few displays available today indicate where the market is going. The most astonishing is the BrightSide HDR display with a claimed contrast ratio of 60,000:1, good enough to reproduce the effect of a sunlit scene. They achieve this using high-power white LEDs.

The only bad thing about the BrightSide display is that once you look at it for a few minutes you just assume that this is how images are supposed to look – it is such a transparently great technology that until you see a normal image on a normal display you don’t really think of the HDR display as that exciting. The display is still in the very-expensive bracket, but this will change quickly.

Of course, HDR displays work best if you have lots of HDR images. I anticipate a huge market for stock HDR imagery. See the Flickr HDR group for starters.

Applications

Today, the main users of HDR imaging devices are specialized professionals working in the film, animation and VR industries. Some applications are listed below (see the Resources page for links).

Film – Tools such as HDRShop by Paul Debevec enable you to convert a series of photographs into a light probe – a special image that represents the lighting environment in a room. You can then use the light probe to light virtual objects, so that the virtual objects actually appear to be lit by the light from the room. This technique is especially useful for compositing computer graphic objects into images of real scenes. Hollywood films use light maps extensively to blend CGI into a scene.

Panoramas – Another use for HDR is in panoramic images. Panoramas often have a wide dynamic range, e.g. one part of the panorama may contain the sun, another part may be in deep shadow. Online web panoramas constructed from HDR images look much better than non-HDR equivalents.

Games – A third use for HDR is in computer games. Recent computer graphics cards support HDR texture maps. With HDR texture maps, you can render objects using light probes, in real time, yielding much more dynamic and interesting lighting effects. “High Dynamic Range Lighting Effects” are now all the range in high-end games.

As more consumer-oriented HDR products arrive, I believe the largest application of HDR will be in consumer photography, though the term HDR is unlikely to be seen – instead you will see branding terminology, e.g. companies will make up words like “DynaChrome”, “MaxBright”, “SuperColor” etc.

Do we really need HDR?

I recently read this comment from Sam Berry:

… the whole article has no mention of the fact that the reason most controlled lighting is almost always done to ratio of less than 8:1 even with neg film /modern digital capable of much more is because that’s what looks good. HDR technology now means you can reproduce your harsh midday sunlit scene perfectly, and it will look identically awful compared to the original.

The debate boils down to this: Does an image with a 300:1 dynamic range look good because it represents a physical sweetspot — something to do with our perceptual system that works well at that ratio? Or is it that all we’ve had access to for hundreds of years are reflective images with a roughly 300:1 dynamic range, so we are accustomed to that?

I had a similar question in my mind before seeing the BrightSide HDR display. Now, after looking at a HDR image on a 50,000:1 HDR display, I am no longer concerned about over-brightness, 50,000:1 is still way less than the brightness of looking directly at the sun. It wasn’t blinding. It isn’t a question of harsh. Images simply looks better when they look more real.

In the coming decade, HDR digital imaging technology will arrive, and change how we take, manipulate, store, use and display images forever.

* * * * *

This next article explains how exactly to do an HDR image with digital technology. It is written by Fabo from hdr101. His site contains further HDR resources.

* * * * *

HDR Tutorial (Photomatix) (English)

This is a basic, standard, step by step tutorial of how to make an HDR Image.(Note: this tutorial is based on building an HDR image from 7 differents shots. My camara doesn’t shoot RAW. More on building an HDR image from a single RAW file, soon!)

The materials for this process are as follows:

Hardware:

* Digital Camera (Obvius, but hey you never know )

* Tripod

Software:

* Photomatix (used for Generating HDR and Tone Mapping)

* Photoshop CS2. (But for this tutorial any version of Photoshop will do. We’ll be using it for retouching only)

Ok, let’s get going!

Taking the pictures:

Put your camera in the tripod. Place it firmly because you’ll have to touch the camera to change the speed and this can make you move it, and then, well you wont be able to get the HDR you were hoping for.

After selecting the subject you wish to shoot, prepare everything as if you were only going to take one picture. Prepare it to your taste or what ever is you want to acomplish.

Set your primary exposure and speed. We are going to call this master setting 0. After this is complete and you have everything set up you are going to take let’s say 7 pictures:

3 pictures up from 0 and 3 pictures down.

Dude what do you mean?? Don’t panic is quite easy:

If the settings for picture 0 is: 1/125 and f/4.5

The settings for the remaining pictures are as follows:

* Picture +3: 1/250 f/4.5

* Picture +2: 1/200 f/4.5

* Picture +1: 1/160 f/4.5

* Picture 0: 1/125 f/4.5 (YOUR MASTER SETTING)

* Picture -1: 1/100 f/4.5

* Picture -2: 1/80 f/4.5

* Picture -3: 1/60 f/4.5

You’ve may noticed that the F/ stays the same. This is quite simple: if that value changes also will you Depth of Field which will cause you focus to change also.

Now that you have taken all your pictures is time to go and kick some Photomatix but!

Ok, so you got to your computer, opened up Photomatix, and oh well you have no idea what to do. No problem becouse this part of the process has litle pictures in it, so you wont have any excuse not to make HDR pictures!!

Photomatix:

Open Photomatix and look for the HDRI tab. Click on it. After you will see GENERATE HDR. Go ahead click some more.

When you do that something like this comes up:

Now you click on the BROWSE button and select the pictures you want:

After you you click the SELECT button a screen like this come along:

Ok. Now your pictures are selected and you click OK. Now you have to choices: to Align Input Images or not to let the software do it. I personally always let the software do it. Is up to you:

Now you’ll get this screen. Depending on you computer memory this may take a while, but not to long. I’ve notice that when one of the picture is to dark or to bright, in Auto Align, Photomatix has a hard time aligning the images. I usually cancel and deselect the image I think is causing the problem:

If everything is ok, this should come up:

After Photomatix is done, it shows you your new Generated HDR Image:

But you want it like does cool ones out there! Wait, there’s more: ToneMapping!

Now you go to the HDRI tab and select Tone Mapping. Here is where the fun begins!

The first thing you may notice is the difference in the picture. Here you have 7 important options:

Luminosity

Strength

Color Saturation

White Clip

Black Clip

Smoothing

MicroContrast

I could go on and explain what all those sliders and buttons do, but we’ll do something better: You try!

Move them up, down, put some more here, take some less there. The idea is for you to experience it for yourself. Trust me, is really fun that way!

So after moving around the sliders i get to a point where i like the results:

I go click on OK, and we go back to the first screen but with the final version of the photo:

Now i want to take it to Photoshop for aditional retouching but first i have to save it. I preffer TIFF format:

Choose your name, location and format:

Now go open Photoshop, and open the TIFF you just saved:

Now go to the IMAGE tab, ADJUSTMENTS. Now you have to play and have fun with each and every other option in there. Try everything and if you do something you don’t like, don’t worry UNDO! (Also play with some filters, they can help to!)

After playing a litle bit, i got to this point which i like:

Now save it again in any format you like. I always save them on TIFF:

Voila! Your first HDR Image. Kind a cool, insn’t?

* * * * *

And the last one is by Sean T. McHugh from his photographic tutorials located on Cambrigdeincolour.

* * * * *

HIGH DYNAMIC RANGE PHOTOGRAPHY

High dynamic range (HDR) images enable photographers to record a greater range of tonal detail than a given camera could capture in a single photo. This opens up a whole new set of lighting possibilities which one might have previously avoided—for purely technical reasons. The new “merge to HDR” feature of Photoshop CS2 allows the photographer to combine a series of bracketed exposures into a single image which encompasses the tonal detail of the entire series. There is no free lunch however; trying to broaden the tonal range will inevitably come at the expense of decreased contrast in some tones. Learning to use the merge to HDR feature in Photoshop CS2 can help you make the most of your dynamic range under tricky lighting—while still balancing this trade-off with contrast.

MOTIVATION: THE DYNAMIC RANGE DILEMMA

As digital sensors attain progressively higher resolutions, and thereby successively smaller pixel sizes, the one quality of an image which does not benefit is its dynamic range. This is particularly apparent in compact cameras with resolutions near 8 megapixels, as these are more susceptible than ever to blow highlights or noisy shadow detail. Further, some scenes simply contain a greater brightness range than can be captured by current digital cameras– of any type.

The “bright side” is that nearly any camera can actually capture a vast dynamic range– just not in a single photo. By varying the shutter speed alone, most digital cameras can change how much light they let in by a factor of 50,000 or more. High dynamic range imaging attempts to utilize this characteristic by creating images composed of multiple exposures, which can far surpass the dynamic range of a single exposure.

WHEN TO USE HDR IMAGES

I would suggest only using HDR images when the scene’s brightness distribution can no longer be easily blended using a graduated neutral density (GND) filter. This is because GND filters extend dynamic range while still maintaining local contrast. Scenes which are ideally suited for GND filters are those with simple lighting geometries, such as the linear blend from dark to light encountered commonly in landscape photography (corresponding to the relatively dark land transitioning into bright sky).

In contrast, a scene whose brightness distribution is no longer easily blended using a GND filter is the doorway scene shown below.

Brightness Distribution Underexposure Overexposure

We note that the above scene contains roughly three tonal regions with abrupt transitions at their edges– therefore requiring a custom-made GND filter. If we were to look at this in person, we would be able to discern detail both inside and outside the doorway, because our eyes would adjust to changing brightness. The goal of HDR use in this article is to better approximate what we would see with our own eyes through the use of a technique called tonal mapping.

INNER WORKINGS OF AN HDR FILE

Photoshop creates an HDR file by using the EXIF information from each of your bracketed images to determine their shutter speed, aperture and ISO settings. It then uses this information to assess how much light came from each image region. Since this light may vary greatly in its intensity, Photoshop creates the HDR file using 32-bits to describe each color channel (as opposed to the usual 16 or 8-bits, as discussed in the tutorial on “Understanding Bit Depth“). The real benefit is that HDR files use these extra bits to create a relatively open-ended brightness scale, which can adjust to fit the needs of your image. The important distinction is that these extra bits are used differently than the extra bits in 16-bit images, which instead just define tones more precisely (see tutorials on the “RAW File Format” and “Posterization“). We refer to the usual 8 and 16-bit files as being low dynamic range (LDR) images, relatively speaking.

The 32-bit HDR file format describes a greater dynamic range by using its bits to specify floating point numbers, also referred to as exponential notation. A floating point number is represented by a fractional numerical value raised to some power of 10, such as 5.467×103, as opposed to the usual 0-255 (for 8-bit) or 0-65535 (for 16-bit) integer color specifications. This way, an image file can specify a brightness of 4,300,000,000 simply as 4.3x109, which would be too large even with 32-bit integers.

We see that the floating point notation certainly looks neater and more concise, but how does this help a computer? Why not just keep adding more bits to specify successively larger numbers, and therefore a larger dynamic range? Recall that for ordinary LDR files, far more bits are used to distinguish lighter tones than darker tones (from the tutorial on gamma correction, tonal levels and exposure – to be added). As a result, as more bits are added, an exponentially greater fraction of these bits are used to specify color more precisely, instead of extending dynamic range.

The more closely spaced bits for brighter values is a result of the fact that ordinary 8 and 16-bit JPEG files are gamma-encoded, which can actually help increase dynamic range for low-bit files; gamma-encoding just becomes more and more inefficient as the bit depth increases.

HDR files get around this LDR dilemma of diminishing returns by using floating point numbers which are proportional to the actual brightness values of the subject matter (gamma equals one, or linear). This ensures that bits are equally spaced throughout the dynamic range, and not just concentrated in the brighter tones– allowing for greater bit efficiency. Further, the use of floating point numbers ensure that all tones are recorded with the same relative precision, since the base (mantissa) in numbers such as 2.576×103 and 8.924×109 each have the same number of significant figures (four), even though the second number is more than a million times larger.

Note: just as how using high bit depth images do not necessarily mean your image contains more color, a high dynamic range file does not guarantee greater dynamic range unless this is also present in the actual subject matter.

All of these extra bits provided by the HDR format are great, and effectively allow for a nearly infinite brightness range to be described. The problem is that your computer display (or the final photographic print) can only show a fixed brightness scale. This tutorial therefore focuses on how to create and convert HDR files into an ordinary 8 or 16-bit image, which can be displayed on a monitor, or will look great as a photographic print. This process is also commonly referred to as tonal mapping.

IN-FIELD PREPARATION

Since creating a HDR image requires capturing a series of identically-positioned exposures, a sturdy tripod is essential. Photoshop has a feature which attempts to align the images when the camera may have moved between shots, however best results are achieved when this is not relied upon.

Make sure to take at least three exposures, although five or more is recommended for optimum accuracy. More exposures allow the HDR algorithm to better approximate how your camera translates light into digital values (a.k.a. the digital sensor’s response curve)– creating a more even tonal distribution. The doorway example is best-suited with several intermediate exposures, in addition to the two shown previously.

Reference -1 Stops -2 Stops -3 Stops

It is essential that the darkest of these exposures includes no blown highlights in areas where you want to capture detail. The darkest exposure should show the darkest regions of the image with enough brightness that they are relatively noise-free and clearly visible. Each exposure should be separated by one to two stops, and these are ideally set by varying the shutter speed (as opposed to aperture or ISO speed). Recall that each “stop” refers to a doubling (+1 stop) or halving (-1 stop) of the light captured from an exposure.

We also note another disadvantage of HDR images: they require relatively static subject matter, due to the necessity of several separate exposures. Our previous ocean sunset example would therefore not be well-suited for the HDR technique, as the waves would have moved significantly between each exposure.

CREATING A 32-BIT HDR FILE IN PHOTOSHOP CS2

Here we use Adobe Photoshop CS2 to convert the sequence of exposures into a single image, which uses tonal mapping to approximate what we would see with our eye. Before tonal mapping can be performed, we first need to combine all exposures into a single 32-bit HDR file.

Open the HDR tool (File>Automate>Merge to HDR…), and load all photographs in the exposure sequence; for this example it would be the four images shown in the previous section. If your images were not taken on a stable tripod, this step may require checking “Attempt to Automatically Align Source Images” (which greatly increases processing time). After pressing OK, you will soon see a “Computing Camera Response Curves” message.

Once your computer has stopped processing, it will show a window with their combined histogram. Photoshop has estimated the white point, but this value often clips the highlights. You may wish to move the white point slider to the rightmost edge of the histogram peaks in order to see all highlight detail. This value is for preview purposes only and will require setting more precisely later. After pressing OK, this leaves you with a 32-bit HDR image, which can now be saved if required. Note how the image may still appear quite dark; only once it has been converted into a 16 or 8-bit image (using tonal mapping) will it begin to look more like the desired result.

At this stage, very few image processing functions can be applied to a 32-bit HDR file, so it is of little use other than for archival purposes. One function which is available is exposure adjustment (Image>Adjustments>Exposure). You may wish to try increasing the exposure to see any hidden shadow detail, or decreasing the exposure to see any hidden highlight detail.

USING HDR TONAL MAPPING IN PHOTOSHOP CS2

Here we use Adobe Photoshop CS2 to convert the 32-bit HDR image into a 16 or 8-bit LDR file using tonal mapping. This requires interpretive decisions about the type of tonal mapping, depending on the subject matter and brightness distribution within the photograph.

Convert into a regular 16-bit image (Image>Mode>16 Bits/Channel…) and you will see the HDR Conversion tool. The tonal mapping method can be chosen from one of four options, described below.

Exposure and Gamma This method lets you manually adjust the exposure and gamma, which serve as the equivalent to brightness and contrast adjustment, respectively. Highlight Compression This method has no options and applies a custom tonal curve, which greatly reduces highlight contrast in order to brighten and restore contrast in the rest of the image. Equalize Histogram This method attempts to redistribute the HDR histogram into the contrast range of a normal 16 or 8-bit image. This uses a custom tonal curve which spreads out histogram peaks so that the histogram becomes more homogenous. It generally works best for image histograms which have several relatively narrow peaks with no pixels in between. Local Adaptation This is the most flexible method and probably the one which is of most use to photographers. Unlike the other three methods, this one changes how much it brightens or darkens regions on a per-pixel basis (similar to local contrast enhancement). This has the effect of tricking the eye into thinking that the image has more contrast, which is often critical in contrast-deprived HDR images. This method also allows changing the tonal curve to better suit the image.

Before using any of the above methods, one may first wish to set the black and white points on the image histogram sliders (see “Using Levels in Photoshop” for a background on this concept). Click on the double arrow next to “Toning Curve and Histogram” to show the image histogram and sliders.

The remainder of this tutorial focuses on settings related to the “local adaptation” method, as this is likely the most-used, and provides the greatest degree of flexibility.

CONCEPT: TONAL HIERARCHY & IMAGE CONTRAST

In contrast to the other three conversion methods, the local adaptation method does not necessarily retain the overall hierarchy of tones. It translates pixel intensities not just with a single tonal curve, but instead also based on the surrounding pixel values. This means that unlike using a tonal curve, tones on the histogram are not just stretched and compressed, but may instead cross positions. Visually, this would mean that some part of the subject matter which was initially darker than some other part could later acquire the same brightness or become lighter than that other part– if even by a small amount.

Underexposed Photo Overexposed Photo Final Composite that Violates Large-Scale Tonal Hierarchy

A clear example where global tonal hierarchy is not violated is the example used in the page on using a GND to extend dynamic range (although this is not how local adaptation works). In this example, even though the foreground sea foam and rock reflections are actually darker than the distant ocean surface, the final image renders the distant ocean as being darker. The key concept here is that over larger image regions our eyes adjust to changing brightness (such as looking up at a bright sky), while over smaller distances our eyes do not. Mimicking this characteristic of vision can be thought of as a goal of the local adaptive method– particularly for brightness distributions which are more complex than the simple vertical blend in the ocean sunset above.

An example of a more complex brightness distribution is shown below for three statue images. We refer to contrast over larger image distances as global contrast, whereas contrast changes over smaller image distances are termed local contrast. The local adaptation method attempts to maintain local contrast, while decreasing global contrast (similar to that performed with the ocean sunset example).

The above example illustrates visually how local and global contrast impact an image. Note how the large-scale (global) patches of light and dark are exaggerated for the case of high global contrast. Conversely, for the case of low global contrast the front of the statue’s face is virtually the same brightness as it’s side.

The original image looks fine since all tonal regions are clearly visible, and shown with sufficient contrast to give it a three-dimensional appearance. Now imagine that we started with the middle image, which would be an ideal candidate for HDR conversion. Tonal mapping using local adaptation would likely produce an image similar to the far right image (although perhaps not as exaggerated), since it retains local contrast while still decreasing global contrast (thereby retaining texture in the darkest and lightest regions).

HDR CONVERSION USING LOCAL ADAPTATION

The distance which distinguishes between local and global contrast is set using the radius value. Radius and threshold are similar to the settings for an unsharp mask used for local contrast enhancement. A high threshold improves local contrast, but also risks inducing halo artifacts, whereas too low of a radius can make the image appear washed out. For any given image, it is recommended to adjust each of these to see their effect, since their ideal combination varies depending on image content.

In addition to the radius and threshold values, images almost always require adjustments to the tonal curve. This technique is identical to that described in the Photoshop curves tutorial, where small and gradual changes in the curve’s slope are nearly always ideal. This curve is shown for our doorway example below, yielding the final result.



HDR images which have been converted into 8 or 16-bit often require touching up in order to improve their color accuracy. Subtle use of levels and saturation can drastically improve problem areas in the image. In general, regions which have increased in contrast (a large slope in the tonal curve) will exhibit an increase in color saturation, whereas the opposite occurs for a decrease in contrast. Changes in saturation may sometimes be desirable when brightening shadows, but in most other instances this should be avoided.

The main problem with the local adaptation method is that it cannot distinguish between incident and reflected light. As a result, it may unnecessarily darken naturally white textures and brighten darker ones. Be aware of this when choosing the radius and threshold settings so that this effect can be minimized.

TIP: USING HDR TO REDUCE SHADOW NOISE

Even if your scene does not require more dynamic range, your final photo may still improve from a side benefit: decreased shadow noise. Ever noticed how digital images always have more noise in the shadows than in brighter tones? This is because the image’s signal to noise ratio is higher where the image has collected more of a light signal. You can take advantage of this by combining a properly exposed image with one which has been overexposed. Photoshop always uses the most exposed image to represent a given tone—thereby collecting more light in the shadow detail (but without overexposing).

RECOMMENDATIONS

Keep in mind that HDR images are extremely new– particularly in the field of digital photography. Existing tools are therefore likely to improve significantly; there is currently, and may never be, an automated single-step process which converts all HDR images into those which look pleasing on screen, or in a print. Good HDR conversions therefore require significant work and experimentation in order to achieve realistic and pleasing final images.

Additionally, incorrectly converted or problematic HDR images may appear washed out after conversion. While re-investigating the conversion settings is recommended as the first corrective step, touch-up with local contrast enhancement may also yield a more pleasing result.

As with all new tools, be careful not to overdo their use. Use care when violating the image’s original tonal hierarchy; do not expect deep shadows to become nearly as light as a bright sky. In our doorway example, the sunlit building and sky are the brightest objects, and they stayed that way in our final image. Overdoing editing during HDR conversion easily can cause the image to lose its sense of realism. Furthermore, HDR should only be used when necessary; best results can always be achieved by having good lighting to begin with.

* * * * *

Next: How The Memoirs got 167000 hits in a few hours…

If you liked this post, share it with others using the icons below.