The 3D Handbook
Topic

Triplanar and world-aligned mapping

Projecting a texture from three directions in world or object space instead of using UVs; how the blend works, how to handle normal maps correctly, what it costs, why textures swim on moving objects, and how to set it up in Unreal, Unity, Godot and Blender.

texturingmaterialsshadersterrain

Triplanar mapping projects a texture onto a surface from three directions (along X, Y and Z) and blends the three results by which way the surface faces. Godot's reference describes it plainly: it "reads from the source texture 3 times, once for each axis and then blends between the results based on how closely the pixel aligns with each axis" (Godot Engine source on GitHub: BaseMaterial3D). Because the coordinates come from position rather than UVs, you can texture rocks, cliffs, terrain and blockouts without unwrapping them.

World-aligned mapping is the same idea computed in world space, so neighbouring objects line up seamlessly. Unreal's version is the WorldAlignedTexture material function (Unreal Engine documentation: Texturing Material Functions in Unreal Engine).

#How it works

For each pixel, the shader does three things (80 Level: UE5 Triplanar Deep Dive: From…):

  1. Make three sets of coordinates from the pixel's position: YZ for the X projection, XZ for Y, XY for Z.
  2. Sample the texture three times, once with each set.
  3. Blend the three samples using weights from the surface normal. A face pointing straight up uses only the top projection; a 45° slope mixes two.

The weights come from the absolute value of each component of the normal. Ben Golus recommends normalising them so they add up to 1 ("Dividing by the sum ensures the new sum is always 1.0") and sharpening them, for example by raising them to a power; he notes "using a hard coded power of 4 is just as fast" as the other optimised options (Medium: Normal Mapping for a Triplanar Shader).

Left, a circle in cross-section with arrows showing the top projection coming down from above and the side projection coming in from the side. The circle's outline is coloured by which projection dominates; narrow orange bands near the 45-degree diagonals mark where the two projections blend. Right, a graph of blend weight against surface angle from 0 to 90 degrees, showing a soft blend curve with power 1 and a much sharper curve with power 4.
Each projection wins where the surface faces it. The blend zones (orange) sit around 45°. Raising the weights to a higher power narrows them, which hides smearing but makes the seam more visible.Diagram by the handbook author

#Blend sharpness

The width of the blend zone is the main artistic control.

  • Soft blends hide the seams between projections but show a "doubled" or ghosted texture where two projections overlap.
  • Sharp blends keep the texture crisp but show a visible change in direction along the seam.

Every engine exposes this. Unreal's WorldAlignedTexture has ProjectionTransitionContrast, which "controls the contrast of the blend where two projection planes meet" (Unreal Engine documentation: Texturing Material Functions in Unreal Engine). Unity's Triplanar node has Blend, where 0 gives each plane equal weight (Unity documentation: Triplanar Node). Godot's uv1_triplanar_sharpness: "A lower number blends the texture more softly while a higher number blends the texture more sharply" (Godot Engine source on GitHub: BaseMaterial3D). Alina Ledeneva also points out that the shape of the mask matters: linear masks give an even 50/50 split at 45°, cosine-based masks a more organic transition on curved shapes (80 Level: UE5 Triplanar Deep Dive: From…).

Textures with natural, non-directional detail (rock, dirt, moss, concrete) hide the seams best. Bricks, planks and anything with obvious direction show them.

#Reorienting normal maps

A normal map stores directions relative to a surface's tangent space, which normally comes from the UVs. Triplanar mapping ignores the UVs, so the mesh's tangents no longer match the texture. Golus explains that the naive approach uses those mesh tangents, and "sometimes you'll get lucky and sometimes they'll be totally wrong". His advice: "Don't do this" (Medium: Normal Mapping for a Triplanar Shader).

The fix is to treat each projection as having its own tangent frame, convert each sampled normal into world space, then blend (80 Level: UE5 Triplanar Deep Dive: From…; Medium: Normal Mapping for a Triplanar Shader). Golus compares several methods (Medium: Normal Mapping for a Triplanar Shader):

  • Swizzle, using the world axes as tangents: correct only for flat, axis-aligned walls.
  • UDN blend: "quite popular because it's so cheap and effective", but flattens normals above about 45°.
  • Whiteout blend: slightly more expensive, less flattening.
  • Reoriented Normal Mapping (RNM): "This method is fantastic", the closest to his reference at a modest extra cost.

Ledeneva adds that blending changes the vector length, so normalise at the very end, after any final transform (80 Level: UE5 Triplanar Deep Dive: From…).

In practice you rarely write this yourself. Unreal ships WorldAlignedNormal (Unreal Engine documentation: Texturing Material Functions in Unreal Engine), and its high-quality variant is described as "more accurate but performance-expensive" (80 Level: UE5 Triplanar Deep Dive: From…). Unity's Triplanar node has a Normal type that returns correctly blended normals (Unity documentation: Triplanar Node).

#Cost

Triplanar mapping triples the texture reads: three samples per texture instead of one (Unity documentation: Triplanar Node). For a full PBR material with base colour, normal and packed masks, that is nine samples instead of three. Godot's reference states that triplanar "is much slower than normal UV texturing" and "unsuitable when you are trying to achieve crisp texturing" (Godot Engine source on GitHub: BaseMaterial3D).

Ways to keep the cost down:

  • Use it only where UVs are impractical: large organic shapes, terrain sides, blockouts. Use UVs on hero props and anything with crisp, directional detail.
  • Triplanar only some layers. For example, triplanar the dirt or moss overlay but keep the main material on UVs.
  • Two projections instead of three where the third is never seen, such as the top and one side of a cliff.
  • Unreal landscapes can use Landscape Layer Coords with XZ or YZ mapping "for side-projected textures", a cheaper way to stop cliffs stretching (Unreal Engine documentation: Landscape Materials in Unreal Engine).

#Swimming on moving objects

A world-space projection is fixed to the world, not to the object. Move or rotate the object and the texture slides across it. Ledeneva calls it a "sliding effect that can be confusing" (80 Level: UE5 Triplanar Deep Dive: From…).

#Examples

#In different tools

#Further reading and watching

Builds a triplanar shader from scratch in Shader Graph and explains the blend weights; the ideas carry over to any engine. Watch on YouTube

References

  1. Godot Engine contributors · BaseMaterial3D (class reference) · Godot Engine source on GitHub · docs · accessed 2026-10-21
  2. Epic Games · Texturing Material Functions in Unreal Engine · Unreal Engine documentation · docs · accessed 2026-10-21
  3. Alina Ledeneva · UE5 Triplanar Deep Dive: From WorldAlignedTexture to High-Quality Normals – Part 1 · 80 Level, 2025 · article · accessed 2026-10-21
  4. Ben Golus · Normal Mapping for a Triplanar Shader · Medium, 2017 · article · accessed 2026-10-21
  5. Unity Technologies · Triplanar Node (Shader Graph 17) · Unity documentation · docs · accessed 2026-10-21
  6. Epic Games · Landscape Materials in Unreal Engine · Unreal Engine documentation · docs · accessed 2026-10-21
  7. Godot Engine contributors · Standard Material 3D and ORM Material 3D · Godot Engine documentation (source on GitHub) · docs · accessed 2026-10-21
  8. Harry Gray · Technical Tips for Environment Artists: Part 2 · 80 Level, 2019 · article · accessed 2026-10-21
  9. Blender Foundation · Image Texture Node · Blender Manual (2.93), 2021 · docs · accessed 2026-10-21

Also consulted

Last updated 2026-10-22