Normal mapping

One technique that is very popular among real-time 3D applications today is normal mapping. Normal mapping creates the illusion of highly detailed geometry on a low-poly model by storing surface normals in a texture map, which is then used to calculate the lighting of the mesh. This method is especially popular in modern games, where it allows developers to strike a balance between high performance and detailed scenes.

Typically, lighting is calculated using nothing but the surface normal of the triangle being rendered, meaning that the entire polygon will be lit as a continuous, smooth surface.

Normal mapping

With normal mapping, the surface normals ...

Get WebGL Beginner's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.