Physics-based rendering-HDR Tone Mapping

Source: Internet
Author: User

In the game engine rendering pipeline, our range of values for R, G, b channel color information is usually set between [0,1] (or [0,255]). Of these, 0 represents no brightness, and 1 represents the maximum brightness that the display can display. Although it is straightforward to understand, it does not reflect the real-world brightness of the situation. In a real-world lighting environment, light intensity can sometimes exceed the maximum brightness displayed by the display. Moreover, the human eye is self-regulating according to the light intensity when observing real-world objects. Therefore, a more realistic rendering is to let the color value exceed 1. This lighting calculation or ambient illumination is the HDR (High Dynamic Range) illumination or HDR environment map we see in the game engine often. However, HDR-rendered luminance values exceed the display's ability to display the maximum value. At this point, we need to convert the lighting results from HDR to LDR that the monitor will display properly. This process we often call tone Mapping. It was the unity engine that used the tone mapping for images that were rendered in HDR and the comparison results without using tone mapping:


The result of which is not using tone mapping, is the result of using the tone mapping. As you can see, in a rendering that does not use tone mapping, a large portion of the brightness of the pixel is greater than the maximum value that the display can display. In a visual sense, these places have become too exposed. In the result of using tone mapping, like light brightness becomes normal and visually more real.

The paper that we are going to present today is the paper "Photographic Tone Reproduction for Digital Images", published in 2002 at the SIGGRAPH Conference. This paper presents a new method of tone mapping, which makes the results of the transformation of the method visually appear to be closer to the real-world objects. First, let's take a look at the result diagram of this paper, as shown in:


The left image is the result of linear scaling, and the right image is the result of the conversion using the algorithm in the paper. As you can see, in the simple linear scaling results, many details are lost, and the result of the algorithm conversion is very good to preserve the detail part of the image. Next, we'll cover the algorithm section in the paper in detail.

First, the initial light degree mapping

First, the author makes a light map of the entire image, which acts like a camera's exposure. This is actually a fixed scaling for each pixel. According to the previous research conclusions on tone mapping, the author thinks that the log average of brightness can reflect the characteristics of the luminance of pixels in the picture. Therefore, the author uses this value to scale each pixel.

If you use lω (x, y) to represent the luminance of a pixel (x, y), the log average can be expressed as:

Where N represents the number of pixels, δ is a constant used to avoid singular values. The brightness of the zoom L (x, y) can be expressed as the following formula:

where α is a scaling parameter, called key value, the different alpha values correspond to different scaling degrees, as shown in:

However, simply doing simple linear scaling is not enough. For the brightness change is not a very large picture, this method can be good to compress the brightness of the pixel to a certain extent, but for most of the picture, most of the pixel brightness is within a certain range, and a few highlighted pixels higher than the average is too much, it is easy to produce excessive exposure, such as: light source, high light reflection. Therefore, it is usually necessary to use the nonlinear operator to process the image after linear scaling. In this paper, a common operator is listed:

where Ld (x, y) represents a pixel that has been processed by a nonlinear operator, Lwhite represents the smallest of the pixels in the picture that are mapped to white brightness. Because it is non-linear, it is more scalable for high-brightness pixels, so the formula can prevent excessive exposure that cannot be handled in linear scaling. However, this simple operator is often prone to loss of detail. The author observes that in traditional printing technology, in order to improve the quality of printing results, a dodying-and-burning method is usually used. The principle of this method is to reduce the brightness (dodying) or increase the brightness (burning) in different areas according to the different printing content. In this paper, the author compares the simple nonlinear mapping and the results of dodying-and-burning processing by experiments, as shown in:

In the upper row, the sun is obscured by branches, so it does not contain highlighted areas, and the picture below contains specular reflections. The picture on the left is also scaled using simple nonlinear operators (simply Operator), which is observed to reveal that the text in the book is completely covered with highlights. This shows that simple nonlinear operator scaling loses a lot of detail.

After observing and testing, the author proposes an adaptive Dodging-and-burning method based on the Dodging-and-burning method, which we will explain in detail below.

Second, adaptive dodging-and-burning

The adaptive dodging-and-burning is characterized by finding areas with large contrast margins and then processing the area. Therefore, the authors propose to use the Gaussian kernel convolution method to find these areas. For different scaling coefficients s, the convolution of Gaussian kernel function Ri (x,y,s) and image L (x, y) is computed at different pixel points (x, y). Then the convolution result Vi (x,y,s) can be expressed as:

where Ri (x,y,s) can be expressed as:

Then, the author defines an error function and calculates the difference of the convolution results of different like parameters to measure the luminance distribution of the image local pixels. The error function V can be expressed as:

By calculating the different scaling parameters s, we find the parameters that conform to the following formula:

of which,? is a threshold value, SM is the scale parameter computed for each pixel. When we get the scaling parameters for each pixel, we do a different scaling calculation for each pixel:

Thus obtaining the final tone mapping result. Shows the calculation process:

The left figure shows the process of calculating the scaling parameters, center represents the range of the inner ring Gaussian calculation, and the surround represents the range of the outer ring Gaussian calculation. The image on the right shows the result of scaling with different scaling parameters. By observing can be sent down, when the zoom is too small to effectively extract the image details, and the scale is too large, there will be black artifacts.

Third, the experimental comparison

The author compares the results of dodging-and-burning calculation with those of predecessors. As shown in the following:



Among them, New operator represents the result of the paper's realization.

Iv. Summary

In this paper, a new algorithm of tone mapping is proposed, which is based on the observation and analysis of dodging-and-burning printing technology, and the method of adaptive dodging-and-burning is proposed for different regions using different scaling coefficients. The ability to convert high-dynamic graphs to low-dynamic graphs prevents the highlighting from being overexposed and can be achieved in both the light and dark sections.

V. Information of the Thesis

Author Information:
Erik Reinhard, a well-known computer graphics scholar, is currently working on Technicolor research and innovation.
Michael Stark, a computer graphics researcher, studied at the University of Utah in the United States;
Peter Shirley, famous computer graphics Daniel, realism rendering expert, visiting professor of the University of Utah, Nvidia chief scientist;
James Ferwerda, a well-known computer graphics scholar and associate professor of Rochester Institute of Technology.

Article Link:
Http://www.cmap.polytechnique.fr/~peyre/cours/x2005signal/hdr_photographic.pdf

This is the Tiger Science and Technology No. 225 original article, Welcome to forward sharing, without the author's authorization do not reprint. If you have any original ideas or new discoveries also welcome to contact us to discuss together. (QQ group 465082844)

About the Boundless learning

"Boundless learning" is the new research column launched by UWA in 2017, we will recommend a very practical academic paper, and comb the research background, principles and methods of implementation. The content focuses on game, VR and AR-related computer graphics fields. is the so-called to ask the canal which is clear, for the Fountainhead come, I hope we in the process of research and development not only know it, but also know its why.

Physics-based rendering-HDR Tone Mapping

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.