Ambient occlusion

From Wikipedia, the free encyclopedia
Jump to: navigation, search
The ambient occlusion map for this scene darkens only the innermost angles of corners.

In computer graphics, ambient occlusion is a shading and rendering technique used to calculate how exposed each point in a scene is to ambient lighting. The enclosed inside of a tube is typically more occluded (and hence darker) than the exposed outer surfaces, and the deeper inside the tube, the more occluded (and darker) it becomes. Ambient occlusion can be seen as an accessibility value that is calculated for each surface point.[1] In scenes with open sky this is done by estimating the amount of visible sky for each point, while in indoor environments only objects within a certain radius are taken into account and the walls are assumed to be the origin of the ambient light. The result is diffuse, non-directional shading effect throughout the scene, casting no clear shadows, but with enclosed and sheltered areas darkened and can affect tone. It is often used as a post-processing effect.

Unlike local methods like Phong shading, ambient occlusion is a global method, meaning the illumination at each point is a function of other geometry in the scene. However, it is a very crude approximation to full global illumination. The appearance achieved by ambient occlusion alone is similar to the way an object appears on an overcast day.

Implementation[edit]

In real-time applications, such as computer games, Screen space ambient occlusion can be used as a faster approximation of true ambient occlusion, using pixel depth rather than scene geometry to form an ambient occlusion map. However, newer technologies are making true ambient occlusion feasible even in real-time.[citation needed]

Ambient occlusion is related to accessibility shading, which determines appearance based on how easy it is for a surface to be touched by various elements (e.g., dirt, light, etc.). It has been popularized in production animation due to its relative simplicity and efficiency. In the industry, ambient occlusion is often referred to as "sky light".[citation needed]

The ambient occlusion shading model has the nice property of offering a better perception of the 3D shape of the displayed objects. This was shown in a paper where the authors report the results of perceptual experiments showing that depth discrimination under diffuse uniform sky lighting is superior to that predicted by a direct lighting model.[2]

The occlusion A_\bar p at a point \bar p on a surface with normal \hat n can be computed by integrating the visibility function over the hemisphere \Omega with respect to projected solid angle:


A_\bar p = \frac{1}{\pi} \int_{\Omega} V_{\bar p,\hat\omega} (\hat n \cdot \hat\omega ) \, \operatorname{d}\omega

where V_{\bar p,\hat\omega} is the visibility function at \bar p, defined to be zero if \bar p is occluded in the direction \hat\omega and one otherwise, and \operatorname{d}\omega is the infinitesimal solid angle step of the integration variable \hat\omega. A variety of techniques are used to approximate this integral in practice: perhaps the most straightforward way is to use the Monte Carlo method by casting rays from the point \bar p and testing for intersection with other scene geometry (i.e., ray casting). Another approach (more suited to hardware acceleration) is to render the view from \bar p by rasterizing black geometry against a white background and taking the (cosine-weighted) average of rasterized fragments. This approach is an example of a "gathering" or "inside-out" approach, whereas other algorithms (such as depth-map ambient occlusion) employ "scattering" or "outside-in" techniques.

In addition to the ambient occlusion value, a "bent normal" vector \hat{n}_b is often generated, which points in the average direction of unoccluded samples. The bent normal can be used to look up incident radiance from an environment map to approximate image-based lighting. However, there are some situations in which the direction of the bent normal is a misrepresentation of the dominant direction of illumination, e.g.,

In this example the bent normal Nb has an unfortunate direction, since it is pointing at an occluded surface.

In this example, light may reach the point p only from the left or right sides, but the bent normal points to the average of those two sources, which is, unfortunately, directly toward the obstruction.

Recognition[edit]

In 2010, Hayden Landis, Ken McGaugh and Hilmar Koch were awarded a Scientific and Technical Academy Award for their work on ambient occlusion rendering.[3]

See also[edit]

References[edit]

  1. ^ Miller, Gavin (1994). "Efficient algorithms for local and global accessibility shading". Proceedings of the 21st annual conference on Computer graphics and interactive techniques. pp. 319–326. 
  2. ^ Langer, M.S.; H. H. Buelthoff (2000). "Depth discrimination from shading under diffuse lighting". Perception 29 (6): 649–660. doi:10.1068/p3060. PMID 11040949. 
  3. ^ Oscar 2010: Scientific and Technical Awards, Alt Film Guide, Jan 7, 2010

External links[edit]