High Dynamic Range Imaging

Chun-Wei Liu Yi-Hsin Liu

National Taiwan University



Traditional digital cameras are limited to capture the luminances of real world. The sensor behind the cameras aggregate the light linearly and can only storage 12 bits integer information. However, it is not enough for displaying the contrast for real world. High dynamic range (HDR) imaging allows a wider dynamic range range of luminances between dark and light than traditional camera techniques. In this project, we implement several algorithms for HDR. In the other hand, we implement some tonemapping methods to show the HDR images on comment display for comparison.


Data Acquisition

We take photos by Nikon D80 and Canon PowerShot G7 with remote control program (Nikon Camera Control and PSRemote) to prevent shaking from the shutter. The original images got from camera are at least 3872x2592 JPEG file. In our experiments, most of images were downsampled to 973x648.

Image Alignment

Although we use tripod and the remote control program to get the exposures, we cannot totally avoid from vibration. To align the images, we implement Median Threshold Bitmap algorithm in [1].

High Dynamic Range Imaging

In this stage we implement Debevec's method in [2] for recovering 12 bits RGB image. First, we choose some pixels which lie on flat area in gradient domain and use these pixels to construct a sparse linear system. We recover curve of each channel by using singular value decomposition (SVD) to solve the linear system. Finally, we interpolate radiance map by the recovering curves and origin set of images.

There are infinite solutions of recovering curves because the system is an ill-pose problem (the available curves may have a shift). To solve this problem, we set the function g(127)=0 according to the paper's suggestion.

The original method selected the sample manually, however we avoid this step by increasing the exposures of each scene. The recovering curves of sample image show as follow:

Recovering Curve
Figure 1. The recovering curves.


After we got the radiance map, we have to remap it to a low dynamic range image for display, which is called tonemapping. Here we implement two methods ([3] and [4]) to achieve the tonemapping.

Gradient Domain

The algorithm proceeds as follow:

  1. Take the logarithm of the image intensity.
  2. According to parameters alpha (weighting), and beta (attenuation level), find the Attenuation Map.
  3. Apply Attenuation map on corresponding gradient.
  4. Solve the Poisson equations to find out image after integration.
  5. Recover color information with parameters.

The internal results show in Figure 2.

Shot1's Map

Figure 2. Current Attenuation Map (Left), Attenuation Map (Middle), Gradient Magnitude (Right).

Bilateral Filter

Proposing by Oppenheim in 1968, under simplified assumptions, a image of Lambertion object can be separate by two part

Image = Illuminance * reflectance

If we want to separate a image, we have to do this on intensity domain. To transform RGB color space to intensity domain with preserving color information, we apply the following transform:

Intensity = 0.2999*R + 0.587*G + 0.114*B
color_r = R / Intensity
color_g = G / Intensity
color_b = B / Intensity

The idea of this approach is using the Bilateral Filter to get the Illuminance (base image with low-frequency information). We use the Bilateral Filter in [5] for efficiency. After got the base layer, we apply the transform above to get Reflectance. Figure 3 shows the result.

Gray Image Base Image Detail Image
Figure 3. The result of Intensity (Left), Illuminance (Middle), and Reflectance (Right).

We transform base layer to log space and perform contrast reduction. Here we use simple linear interpretation to handle the base layer. After that, we combine the color information to reproduce a LDR image.


Our results and parameter show as follow:

Files/Methods Gradient Bilateral Photomatix
photo2.JPG t2 b2 p2
shot1.JPG t1 b1 p1
shot5.JPG t5 b5 p5

Table 1. Images results of different tonemapping.

Files/Methods Gradient Bilateral Photomatix
photo2.JPG (0.1, 0.91, 0.7) Defalut (100, 100, 0)
shot1.JPG (0.1, 0.9, 0.7) Defalut (100, 100, -7)
shot5.JPG (0.1, 0.82, 0.7) Defalut (89, 100, 8)

Table 2. Parameters of different tonemapping


  1. “Fast, Robust Image Registration for Compositing High Dynamic Range Photographs from Handheld Exposures.” [Link]
    Greg Ward.
    Journal of Graphics Tools, 8(2):17-30, 2003.
  2. “Recovering High Dynamic Range Radiance Maps from Photograph.s” [Link]
    Paul E. Debevec and Jitendra Malik.
  3. “Gradient Domain High Dynamic Range Compression.” [Link]
    Raanan Fattal, Dani Lischinski and Michael Werman.
  4. “Fast Bilateral Filtering for the Display of High-Dynamic-Range Images.” [Link]
    Frédo Durand and Julie Dorsey.
  5. “A Fast Approximation of the Bilateral Filter using a Signal Processing Approach”. [Link]
    Sylvain Paris and Frédo Durand.
    ECCV 2006