---
id: "octahedral-impostors"
title: "Octahedral impostors"
aliases: [octahedral imposter, hemi-octahedral impostor, parallax impostor]
domain: "performance"
stage: "performance"
realtime: "realtime"
platforms: [webgl2, webgpu, desktop-gpu, unity, unreal, godot]
year_introduced: 2018
inputs: [mesh, material-params]
outputs: [texture, gbuffer]
style: "both"
dynamic: "both"
cost: "cheap"
authority: "Brucks"
url: "https://texelatlas.vercel.app/t/octahedral-impostors/"
sources_verified_at: "2026-11-29"
---
# Octahedral impostors (Brucks)

> Replace distant, complex meshes with a quad that samples a pre-baked atlas of views taken from directions on an octahedron, blending the nearest frames for smooth viewpoint changes.

## Reach for it when

- thousands of trees too heavy to render as meshes
- distant props look flat when camera moves around
- need cheap far lods for foliage with lighting
- billboards look wrong from different angles

## How it works

Bake: render the object from a grid of camera directions covering the sphere (or upper hemisphere for plants and props that sit on the ground). Directions are mapped to a square atlas through octahedral encoding, which spreads samples evenly and avoids pole singularities. Each frame stores albedo, normals and often depth, so the impostor can be relit at runtime.

Runtime: a camera-facing quad computes the view direction in object space, finds the three nearest baked frames, and blends them using barycentric weights. With the stored depth, a parallax step offsets each frame's lookup so the silhouette and internal parallax stay plausible; this is the 'parallax' variant. Output goes into the G-buffer, so lighting and shadows treat it like geometry.

## When to use it

Choose it for dense vegetation, rocks and props at far LOD where triangle count or overdraw dominates. Prefer [Nanite virtualized geometry](https://texelatlas.vercel.app/t/nanite-virtualized-geometry.md) or [Meshlets (cluster rendering)](https://texelatlas.vercel.app/t/meshlets.md) with continuous simplification when the engine supports it and you want no baked data. Prefer plain mesh LOD from [meshoptimizer mesh optimization](https://texelatlas.vercel.app/t/meshoptimizer.md) when objects stay within moderate distance, since impostors cannot be seen up close.

## Cost

cheap — One quad per instance, a few texture fetches; baking is offline and atlas memory scales with frame count and channels.
Measured GPU Weight: 2.81× baseline (light) — 0.0923 ms median / 0.0929 ms p95 on Tesla T4/PCIe/SSE2 @ 1920x1080 (opengl-timer-query).
Ada L4 scaling: 2.16× baseline (light) — 0.0343 ms median (2.69× faster on L4).
Ampere A100 scaling: 1.56× baseline (feather) — 0.0449 ms median (2.06× faster on A100).

## Failure modes

- Visible popping or ghosting when blending between frames, since neighbouring views disagree on silhouettes
- Parallax distortion at grazing angles because stored depth is a single layer
- Baked lighting or shadows leak if the atlas contains shading rather than material data
- Wrong results for animated or deformed meshes, such as wind-bent trees, without a separate vertex animation path
- Atlas memory cost grows quickly with frame resolution and channel count

## Dataflow

- Inputs: mesh, material-params
- Outputs: texture, gbuffer
- Platforms: webgl2, webgpu, desktop-gpu, unity, unreal, godot

## Presets

### Octahedral impostor atlas of baked box views, 8x8 directions (glsl-fragment; rendered 2026-11-29)

```json
{
  "GRID": 8
}
```

```glsl
// Octahedral impostor atlas: each cell is a baked orthographic view of a box from the direction that cell encodes via octahedral mapping.
const float GRID = 8.0;
vec3 octDecode(vec2 e) {
    vec2 f = e * 2.0 - 1.0;
    vec3 n = vec3(f.x, 1.0 - abs(f.x) - abs(f.y), f.y);
    if (n.y < 0.0) n.xz = (1.0 - abs(n.zx)) * sign(n.xz);
    return normalize(n);
}
void mainImage(out vec4 fragColor, in vec2 fragCoord) {
    vec2 uv = fragCoord / iResolution.xy * GRID;
    vec2 cell = floor(uv), f = fract(uv) * 2.0 - 1.0;
    vec3 dir = octDecode((cell + 0.5) / GRID);        // camera direction for this cell
    vec3 fw = -dir;
    vec3 up = abs(dir.y) > 0.95 ? vec3(0, 0, 1) : vec3(0, 1, 0);
    vec3 rt = normalize(cross(fw, up)); up = cross(rt, fw);
    vec3 ro = dir * 4.0 + (rt * f.x + up * f.y) * 1.25;
    vec3 inv = 1.0 / fw;
    vec3 h = vec3(0.55, 0.9, 0.55);
    vec3 ta = (-h - ro) * inv, tb = (h - ro) * inv;
    vec3 tn = min(ta, tb), tf = max(ta, tb);
    float t0 = max(max(tn.x, tn.y), tn.z), t1 = min(min(tf.x, tf.y), tf.z);
    vec3 col = vec3(0.07, 0.08, 0.11) + 0.5 * vec3(0.1, 0.15, 0.3) * (0.5 + 0.5 * dir.y) * 0.4;
    // hit a lower smaller box on top to give the silhouette shape
    if (t1 > max(t0, 0.0)) {
        vec3 p = ro + fw * t0;
        vec3 n = -sign(fw) * step(tn.yzx, tn.xyz) * step(tn.zxy, tn.xyz);
        float dif = max(dot(n, normalize(vec3(0.5, 0.8, 0.4))), 0.0);
        vec3 alb = abs(n.y) > 0.5 ? vec3(0.9, 0.75, 0.45) : (abs(n.x) > 0.5 ? vec3(0.4, 0.65, 0.9) : vec3(0.9, 0.45, 0.4));
        float stripe = 0.85 + 0.15 * sin(p.y * 14.0);
        col = alb * (0.25 + 0.8 * dif) * stripe;
    }
    vec2 g = abs(f);
    col = mix(col, vec3(0.0), smoothstep(0.03, 0.0, 1.0 - max(g.x, g.y)));
    fragColor = vec4(pow(col, vec3(0.8)), 1.0);
}

```

Attribution: written for this index

## Lineage

- extended by [Silhouette-Strip Depth-Parallax Octahedral Impostors](https://texelatlas.vercel.app/t/silhouette-strip-octahedral-impostors.md)

## Combines with

- [GPU-driven rendering](https://texelatlas.vercel.app/t/gpu-driven-rendering.md): Culling produces a per-instance LOD choice that switches far instances to impostor quads in the same indirect draw.

## Combination ideas

- [Dithered impostor forests, temporally rebuilt](https://texelatlas.vercel.app/ideas/impostor-forest-temporal-upscale/)
- [Far LOD for captured splat objects](https://texelatlas.vercel.app/ideas/splat-captures-impostor-lod/)

## Sources

1. [primary] Ryan Brucks Octahedral Impostors. shaderbits.com. https://shaderbits.com/blog/octahedral-impostors (verified via http on 2026-11-30)
2. [implementation] agargaro (2025) agargaro/octahedral-impostor. https://github.com/agargaro/octahedral-impostor License: MIT. (verified via github on 2026-11-29)
3. [implementation] wojtekpil (2020) wojtekpil/Godot-Octahedral-Impostors. https://github.com/wojtekpil/Godot-Octahedral-Impostors License: MIT. (verified via github on 2026-11-29)
4. [tutorial] Vlad Krutenyuk (2026) Octahedral Tree Impostors with Depth Parallax and Silhouette Strips. kvyverse. https://kvyverse.com/octahedral-tree-impostors (verified via http on 2026-11-30)
5. [implementation] Vlad Krutenyuk (2026) Octahedral Tree Impostors Live Source (Three.js). kvyverse Editor. https://kvyverse.com/editor/world/6b0041d2e78fe5de949e5722 (verified via http on 2026-11-30)

## Cite this entry

Texel. "Octahedral impostors." https://texelatlas.vercel.app/t/octahedral-impostors/ (accessed 2026-12-01).
