Parallax Mapping |
The ParallaxMappingSample (see Samples) shows how to implement a new light type which adds environment map reflections to all materials in the scene. This article provides additional background information and explanations.
This topic contains the following sections:
The new ParallaxMappingSample shows how to add a new materials that support Parallax Mapping with Offset Limiting and Parallax Occlusion Mapping.
Parallax mapping is an enhancement of normal mapping. While normal mapping makes bumps and dents appear under lighting, parallax mapping gives the material the appearance of depth – as shown in the following screenshots:
The ground on the left is created using 3 texture maps:
Parallax mapping uses an additional height map:
The height map is used to offset the lookup into the other texture maps. This way, we can create the appearance of depth – even if the ground consists only of a flat triangles. There are many resources, which explain how parallax mapping works, for example [3] and [4].
In addition to standard Parallax Mapping with Offset Limiting and Parallax Occlusion Mapping, the sample code shows: