Course contentsShow
← Unity Game Development
Lesson 612 of 8289. Rendering and VisualsFree lesson

Simulating Surface Details with Normal Maps

Transform flat surfaces into detailed meshes by blending and scaling normal maps to simulate complex geometric depth and lighting.

In this lesson, you will learn how to manipulate normal maps to simulate intricate geometric depth on otherwise flat surfaces, enhancing visual fidelity without increasing polygon counts.

The Physics of Perceived Depth

A normal map works by storing directional vectors in the RGB channels of a texture, which correspond to the X, Y, and Z axes of a surface’s orientation. When the shader calculates lighting, it replaces the flat surface's original "Normal" (the direction it faces) with the data stored in the map. This tricks the eye into seeing bumps, cracks, and engravings because the light reflects off these virtual angles as if they were actual 3D geometry.

Blending and Scaling Normal Maps

To achieve high-quality results, you often need to blend multiple maps—such as a base texture and a micro-detail noise map—to break up repetition. In Shader Graph, you can achieve this using a Normal Blend node.

If a surface looks too "flat" or the details are too extreme, you should adjust the Normal Strength. In a custom shader or a standard Lit material, this effectively acts as a multiplier for the Z-channel of the normal map. If you are building a custom graph, you can construct this logic like so:

// Conceptually, you scale the normal effect:
float3 modifiedNormal = float3(baseNormal.rg * strength, baseNormal.b);
modifiedNormal = normalize(modifiedNormal);

Strategic Implementation

When implementing these maps, remember that they only affect lighting calculations. They do not change the physical silhouette of the object. For optimal performance, always ensure your normal maps are imported with the Normal Map type setting in Unity. This ensures the texture is decompressed correctly to preserve the vector data, which is essential for accurate shading. If you apply a normal map to a surface that is perfectly smooth, the light will hit it uniformly; by using a normal map, you introduce varied surface normals that cause the light to catch on the "edges" of your simulated detail, creating that satisfying, tactile depth.

Key Takeaway: Normal maps allow you to maintain high-performance, low-poly geometry while using texture-based vector data to simulate complex lighting interactions that define surface depth.