TGJ3M_Digital_Imaging_HDR

include component="page" page="course_tabs_header" include component="page" page="menu_TGJ3M_crumbs" include component="page" page="menu_TGJ3M_Digital_Imaging_Graphic_Design_crumbs"

HIGH DYNAMIC RANGE PHOTOGRAPHY -
[|source]

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 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 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 blown 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
When you are shooting a situation where you have a large gradient of light quality, high highs and low lows.



Becomes -->

Usually, a gradient filter, one protecting the foreground, but generally darkening the tones as the gradient becomes solid past the horizon is preferred. But there are times when there simply isn't enough 'information' in the sky to bring out detail without underexposing the foreground. The below photos of the doorway scene are examples of this. (light/dark) || Underexposure || Overexposure || 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 is to better //approximate// what we would see with our own eyes through the use of a technique called tonal mapping.
 * [[image:http://images.cambridgeincolour.com/tutorials/hdr_door-brightdist.jpg]] || [[image:http://images.cambridgeincolour.com/tutorials/hdr_door-lowexp.jpg]] || [[image:http://images.cambridgeincolour.com/tutorials/hdr_door-hiexp.jpg]] ||
 * Brightness Distribution

While Shooting
[|source] 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. It is essential that the darkest of these exposures includes no blown highlights in areas where you want to capture detail. The brightest 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.
 * [[image:http://images.cambridgeincolour.com/tutorials/hdr_image1.jpg]] || [[image:http://images.cambridgeincolour.com/tutorials/hdr_image2.jpg]] || [[image:http://images.cambridgeincolour.com/tutorials/hdr_image3.jpg]] || [[image:http://images.cambridgeincolour.com/tutorials/hdr_image4.jpg]] ||
 * Reference || -1 Stops || -2 Stops || -3 Stops ||

CREATING A 32-BIT HDR FILE IN PHOTOSHOP
Here we use Adobe Photoshop 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
Here we use Adobe Photoshop 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. 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.
 * ~ 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. ||

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.
 * [[image:http://images.cambridgeincolour.com/tutorials/new_dynamic-range_ex1a.jpg width="149" height="228"]] || [[image:http://images.cambridgeincolour.com/tutorials/new_dynamic-range_ex1b.jpg width="149" height="228"]] || [[image:http://images.cambridgeincolour.com/tutorials/new_dynamic-range_ex2b.jpg width="149" height="228"]] ||
 * Underexposed Photo || Overexposed Photo || Final Composite that Violates Large-Scale Tonal Hierarchy ||

**Good HDR conversions require significant work and experimentation in order to achieve realistic and pleasing final images.** 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.

 =Assignment #6A - HDR tutorial= [|source]

Go into my Handout folder for TGJ3M and get the pictures in the Harbour.7z package (copy them to your computer then right click and unzip them to that folder). You should have some pictures you can now bring into Photoshop. Go into the File menu, then the Automate submenu, then select "Merge to HDR":



In the dialog box the pops up, select the files you want to use to make the HDR. Ideally, do not check the "Align automatically" box, unless you screwed up your tripoding and moved the camera between photos. The automatic alignment feature doesn't usually work so great, so it's really a last resort. That said, I used a balcony railing to take the pictures and you WILL needs to check automatically align. *le sigh*



You will end up with a preview window that shows you a preview of your HDR that looks like this:



Just click okay -- you likely don't need to adjust the histogram on the top right. The histogram adjustment affects the baseline for the curves in the next step but for all practical purposes it doesn't matter for what we're trying to do right now. After a loooong while (or a short while if you have a fast computer and a lot of RAM), it'll finish and show you your new HDR image. Cool! You can save this file if you want; it's a 32 bit image file that contains all the exposure data from all of your shots.

But wait, we're not done yet! We want the photo to look good on our monitor. How do we do that? Easy, we downsample (reduce the picture quality). Go to the Image menu, the mode submenu, and select "16 bits per channel".



You end up with a new menu. Toggle the Histogram arrow at the bottom to show the histogram. Go into the little menu at to and select "__**Local Adaptation**__":



You ask yourself - what is the sauce are curves?!?! [|Here is a great resource for you]. Don't worry if you don't completely understand it. Generally you want to approximate an 'S' curve on this HDR merge (NOT what I did above).

When you're done, click okay. After a little while, viola! You get a nice 16 bit image. Tone this to your taste using Layer Adjusts in the layers panel. Save it as a 16bit file, if you like. However, when you're done, you need to downconvert it to 8-bit in order to save it as a JPEG. Go to the Image menu, the mode submenu, and select "8 bits per channel". Save your final work and submit it as assignment #5. The goal is slightly heightened realism as opposed to a dream. Save the file as an 8-bit JPG and target the filesize to be 400KB.

Evaluation:

 * **CATEGORY** || **4** || **3** || **2** || **1** ||
 * **HDR originals** || Judicious use of picture combinations and curves lead to an exemplary product || Small errors in the use of the tools results in a product that is completely acceptable, but does contain noticeable flaws || The piece has many distracting elements but the attempt at a HDR picture is obvious. || The use of the tools produces a largely flawed work. ||
 * **Presentation** || Stylistic choices show no errors in judgment || Overall the piece is well constructed, but the presentation is somewhat lacking. || Generally the piece is satisfactorily constructed, but the presentation is lacking in many areas. || The HDR picture is incomplete, or shows signs of obvious neglect in presentation. ||
 * **Use of Time** || Used time well during each class period (as shown by observation by teacher, and documentation of progress in journal) with no reminders. || Used time well during most class periods (as shown by observation by teacher, and documentation of progress in journal) with no reminders. || Used time well (as shown by observation by teacher and documentation of progress in journal), but required reminders on one or more occasions to do so. || Used time poorly (as shown by observation by teacher and/or documentation of progress in journal) in spite of several reminders to do so. ||
 * **Filetype and size** ||  || The bit-sampling is correct (8-bits) and filesize is appropriate. || Either the file is not 8-bit or the filesize is in appropriate || There is a submission but that's about it. ||



Assignment #6B - HDR Photograph
You are to take a tripod and a camera and find a location/subject that you think will make a good HDR picture. Once taken, you should have bracketed (with your +/- on your camera) 5 pictures. (+2, +1, 0, -1, -2 Exposure settings)



Bring the pictures in to Photoshop and merge them, selecting a good blend of all layers using the information above. Title the piece appropriately, then save it as a PSD (for your records) and an 8-bit 400kB JPG (for evaluation). Submit this JPG to the handin folder.

Evaluation:

 * **CATEGORY** || **4** || **3** || **2** || **1** ||
 * **HDR originals** || Judicious use of picture combination, layers adjust and curves lead to an exemplary product || Small errors in the use of the tools results in a product that is completely acceptable, but does contain noticeable flaws || The piece has many distracting elements but the attempt at a HDR picture is obvious. || Either in taking the pictures, or in the use of the tools afterwards, the work is largely flawed. ||
 * **Presentation** || Stylistic choices show no errors in judgment || Overall the piece is well constructed, but the presentation is somewhat lacking. || Generally the piece is satisfactorily constructed, but the presentation is lacking in many areas. || The HDR picture is incomplete, or shows signs of obvious neglect in presentation. ||
 * **Use of Time** || Used time well during each class period (as shown by observation by teacher, and documentation of progress in journal) with no reminders. || Used time well during most class periods (as shown by observation by teacher, and documentation of progress in journal) with no reminders. || Used time well (as shown by observation by teacher and documentation of progress in journal), but required reminders on one or more occasions to do so. || Used time poorly (as shown by observation by teacher and/or documentation of progress in journal) in spite of several reminders to do so. ||
 * **Filetype and size** ||  || The name format is correct and filesize is appropriate. || Either the naming convention is incorrect or the filesize is in appropriate || There is a submission but that's about it. ||