Environment mapping
   HOME

TheInfoList



OR:

In
computer graphics Computer graphics deals with generating images with the aid of computers. Today, computer graphics is a core technology in digital photography, film, video games, cell phone and computer displays, and many specialized applications. A great de ...
, environment mapping, or reflection mapping, is an efficient
image-based lighting Image-based lighting (IBL) is a 3D rendering technique which involves capturing an omnidirectional representation of real-world light information as an image, typically using a 360° camera. This image is then projected onto a dome or sphere analog ...
technique for approximating the appearance of a
reflective Reflection is the change in direction of a wavefront at an interface between two different media so that the wavefront returns into the medium from which it originated. Common examples include the reflection of light, sound and water waves. The ' ...
surface by means of a precomputed
texture Texture may refer to: Science and technology * Surface texture, the texture means smoothness, roughness, or bumpiness of the surface of an object * Texture (roads), road surface characteristics with waves shorter than road roughness * Texture ...
. The texture is used to store the image of the distant environment surrounding the rendered object. Several ways of storing the surrounding environment have been employed. The first technique was
sphere mapping In computer graphics, sphere mapping (or spherical environment mapping) is a type of reflection mapping that approximates reflective surfaces by considering the environment to be an infinitely far-away spherical wall. This environment is stored as ...
, in which a single texture contains the image of the surroundings as reflected on a
spherical mirror A curved mirror is a mirror with a curved reflecting surface. The surface may be either ''convex'' (bulging outward) or ''concave'' (recessed inward). Most curved mirrors have surfaces that are shaped like part of a sphere, but other shapes are ...
. It has been almost entirely surpassed by
cube mapping In computer graphics, cube mapping is a method of environment mapping that uses the six faces of a cube as the map shape. The environment is projected onto the sides of a cube and stored as six square textures, or unfolded into six regions of a s ...
, in which the environment is projected onto the six faces of a cube and stored as six square textures or unfolded into six square regions of a single texture. Other projections that have some superior mathematical or computational properties include the
paraboloid In geometry, a paraboloid is a quadric surface that has exactly one axis of symmetry and no center of symmetry. The term "paraboloid" is derived from parabola, which refers to a conic section that has a similar property of symmetry. Every plan ...
mapping, the
pyramid A pyramid (from el, πυραμίς ') is a structure whose outer surfaces are triangular and converge to a single step at the top, making the shape roughly a pyramid in the geometric sense. The base of a pyramid can be trilateral, quadrilat ...
mapping, the
octahedron In geometry, an octahedron (plural: octahedra, octahedrons) is a polyhedron with eight faces. The term is most commonly used to refer to the regular octahedron, a Platonic solid composed of eight equilateral triangles, four of which meet at ea ...
mapping, and the
HEALPix HEALPix (sometimes written as Healpix), an acronym for Hierarchical Equal Area isoLatitude Pixelisation of a 2-sphere, is an algorithm for pixelisation of the 2-sphere and the associated class of map projections. The pixelisation algorithm was de ...
mapping. Reflection mapping is one of several approaches to reflection rendering, alongside e.g. screen space reflections or ray tracing which computes the exact reflection by tracing a ray of light and following its
optical path Optical path (OP) is the trajectory that a light ray follows as it propagates through an optical medium. The geometrical optical-path length or simply geometrical path length (GPD) is the length of a segment in a given OP, i.e., the Euclidean dis ...
. The reflection color used in the shading computation at a
pixel In digital imaging, a pixel (abbreviated px), pel, or picture element is the smallest addressable element in a raster image, or the smallest point in an all points addressable display device. In most digital display devices, pixels are the ...
is determined by calculating the reflection vector at the point on the object and mapping it to the
texel Texel (; Texels dialect: ) is a municipality and an island with a population of 13,643 in North Holland, Netherlands. It is the largest and most populated island of the West Frisian Islands in the Wadden Sea. The island is situated north of Den ...
in the environment map. This technique often produces results that are superficially similar to those generated by raytracing, but is less computationally expensive since the radiance value of the reflection comes from calculating the angles of incidence and reflection, followed by a texture lookup, rather than followed by tracing a ray against the scene geometry and computing the radiance of the ray, simplifying the
GPU A graphics processing unit (GPU) is a specialized electronic circuit designed to manipulate and alter memory to accelerate the creation of images in a frame buffer intended for output to a display device. GPUs are used in embedded systems, mobi ...
workload. However, in most circumstances a mapped reflection is only an approximation of the real reflection. Environment mapping relies on two assumptions that are seldom satisfied: # All radiance incident upon the object being shaded comes from an infinite distance. When this is not the case the reflection of nearby geometry appears in the wrong place on the reflected object. When this is the case, no parallax is seen in the reflection. # The object being shaded is
convex Convex or convexity may refer to: Science and technology * Convex lens, in optics Mathematics * Convex set, containing the whole line segment that joins points ** Convex polygon, a polygon which encloses a convex set of points ** Convex polytop ...
, such that it contains no self-interreflections. When this is not the case the object does not appear in the reflection; only the environment does. Environment mapping is generally the fastest method of rendering a reflective surface. To further increase the speed of rendering, the renderer may calculate the position of the reflected ray at each vertex. Then, the position is interpolated across polygons to which the vertex is attached. This eliminates the need for recalculating every pixel's reflection direction. If
normal mapping In 3D computer graphics, normal mapping, or Dot3 bump mapping, is a texture mapping technique used for faking the lighting of bumps and dents – an implementation of bump mapping. It is used to add details without using more polygons. A common ...
is used, each polygon has many face normals (the direction a given point on a polygon is facing), which can be used in tandem with an environment map to produce a more realistic reflection. In this case, the angle of reflection at a given point on a polygon will take the normal map into consideration. This technique is used to make an otherwise flat surface appear textured, for example corrugated metal, or brushed aluminium.


Types


Sphere mapping

Sphere mapping In computer graphics, sphere mapping (or spherical environment mapping) is a type of reflection mapping that approximates reflective surfaces by considering the environment to be an infinitely far-away spherical wall. This environment is stored as ...
represents the
sphere A sphere () is a geometrical object that is a three-dimensional analogue to a two-dimensional circle. A sphere is the set of points that are all at the same distance from a given point in three-dimensional space.. That given point is th ...
of incident illumination as though it were seen in the reflection of a reflective sphere through an orthographic camera. The texture image can be created by approximating this ideal setup, or using a
fisheye lens A fisheye lens is an ultra wide-angle lens that produces strong visual distortion intended to create a wide panoramic or hemispherical image. Fisheye lenses achieve extremely wide angles of view, well beyond any rectilinear lens. Instead of p ...
or via prerendering a scene with a spherical mapping. The spherical mapping suffers from limitations that detract from the realism of resulting renderings. Because spherical maps are stored as
azimuthal projection In cartography, map projection is the term used to describe a broad set of transformations employed to represent the two-dimensional curved surface of a globe on a plane. In a map projection, coordinates, often expressed as latitude and longitu ...
s of the environments they represent, an abrupt point of singularity (a " black hole" effect) is visible in the reflection on the object where texel colors at or near the edge of the map are distorted due to inadequate resolution to represent the points accurately. The spherical mapping also wastes pixels that are in the square but not in the sphere. The artifacts of the spherical mapping are so severe that it is effective only for viewpoints near that of the virtual orthographic camera.


Cube mapping

Cube mapping In computer graphics, cube mapping is a method of environment mapping that uses the six faces of a cube as the map shape. The environment is projected onto the sides of a cube and stored as six square textures, or unfolded into six regions of a s ...
and other polyhedron mappings address the severe distortion of sphere maps. If cube maps are made and filtered correctly, they have no visible seams, and can be used independent of the viewpoint of the often-virtual camera acquiring the map. Cube and other polyhedron maps have since superseded sphere maps in most computer graphics applications, with the exception of acquiring
image-based lighting Image-based lighting (IBL) is a 3D rendering technique which involves capturing an omnidirectional representation of real-world light information as an image, typically using a 360° camera. This image is then projected onto a dome or sphere analog ...
. Image-based lighting can be done with parallax-corrected cube maps. Generally, cube mapping uses the same skybox that is used in outdoor renderings. Cube-mapped reflection is done by determining the
vector Vector most often refers to: *Euclidean vector, a quantity with a magnitude and a direction *Vector (epidemiology), an agent that carries and transmits an infectious pathogen into another living organism Vector may also refer to: Mathematic ...
that the object is being viewed at. This ''camera ray'' is reflected about the surface normal of where the camera vector intersects the object. This results in the ''reflected ray'' which is then passed to the
cube map In computer graphics, cube mapping is a method of environment mapping that uses the six faces of a cube as the map shape. The environment is projected onto the sides of a cube and stored as six square textures, or unfolded into six regions of a s ...
to get the
texel Texel (; Texels dialect: ) is a municipality and an island with a population of 13,643 in North Holland, Netherlands. It is the largest and most populated island of the West Frisian Islands in the Wadden Sea. The island is situated north of Den ...
which provides the radiance value used in the lighting calculation. This creates the effect that the object is reflective.


HEALPix mapping

HEALPix HEALPix (sometimes written as Healpix), an acronym for Hierarchical Equal Area isoLatitude Pixelisation of a 2-sphere, is an algorithm for pixelisation of the 2-sphere and the associated class of map projections. The pixelisation algorithm was de ...
environment mapping is similar to the other polyhedron mappings, but can be hierarchical, thus providing a unified framework for generating polyhedra that better approximate the sphere. This allows lower distortion at the cost of increased computation.Tien-Tsin Wong, Liang Wan, Chi-Sing Leung, and Ping-Man Lam
Real-time Environment Mapping with Equal Solid-Angle Spherical Quad-Map
Shader X4: Lighting & Rendering, Charles River Media, 2006.


History

Precursor work in texture mapping had been established by
Edwin Catmull Edwin Earl "Ed" Catmull (born March 31, 1945) is an American computer scientist who is the co-founder of Pixar and was the President of Walt Disney Animation Studios. He has been honored for his contributions to 3D computer graphics, including th ...
, with refinements for curved surfaces by James Blinn, in 1974. Blinn went on to further refine his work, developing environment mapping by 1976.
Gene Miller Gene Miller (1928–2005) was a longtime investigative reporter at the ''Miami Herald'' who won two Pulitzer Prizes for reporting that helped save innocent men on Florida's Death Row from execution. He was also a legendary editor, mentoring genera ...
experimented with spherical environment mapping in 1982 at MAGI Synthavision. Wolfgang Heidrich introduced Paraboloid Mapping in 1998. Emil Praun introduced Octahedron Mapping in 2003. Mauro Steigleder introduced Pyramid Mapping in 2005.Mauro Steigleder. "Pencil Light Transport". A thesis presented to the University of Waterloo, 2005. Tien-Tsin Wong, et al. introduced the existing
HEALPix HEALPix (sometimes written as Healpix), an acronym for Hierarchical Equal Area isoLatitude Pixelisation of a 2-sphere, is an algorithm for pixelisation of the 2-sphere and the associated class of map projections. The pixelisation algorithm was de ...
mapping for rendering in 2006.


See also

*
Skybox (video games) A skybox is a method of creating backgrounds to make a video game level appear larger than it really is. When a skybox is used, the level is enclosed in a cuboid. The sky, distant mountains, distant buildings, and other unreachable objects ...


References


External links


The Story of Reflection mapping
by
Paul Debevec Paul Ernest Debevec is a researcher in computer graphics at the University of Southern California's Institute for Creative Technologies. He is best known for his work in finding, capturing and synthesizing the bidirectional scattering distribution ...

NVIDIA's paper
Cube Environment Mapping
Approximation of reflective and transparent objects with environmental maps
{{DEFAULTSORT:Reflection Mapping 3D rendering Demo effects