{
 "id": "silhouette-strip-octahedral-impostors",
 "title": "Silhouette-Strip Depth-Parallax Octahedral Impostors",
 "aliases": [
  "GTA 6 octahedral impostors",
  "silhouette-strip impostors",
  "depth-parallax octahedral tree impostors",
  "bit-packed silhouette strip impostors"
 ],
 "domain": "performance",
 "subdomain": "impostors",
 "stage": "performance",
 "realtime": "realtime",
 "platforms": [
  "webgl2",
  "webgpu",
  "desktop-gpu",
  "unity",
  "unreal",
  "godot"
 ],
 "year_introduced": 2026,
 "inputs": [
  "mesh",
  "material-params"
 ],
 "outputs": [
  "texture",
  "gbuffer"
 ],
 "style": "both",
 "dynamic": "both",
 "summary": "Refines 64-view octahedral impostors with vertex-merged 8-strip bit-packed silhouettes to cut transparent overdraw and per-fragment camera-ray depth parallax to eliminate ghosting across the three blended views.",
 "how_it_works": "Standard single-quad [octahedral-impostors](octahedral-impostors) waste substantial fragment shader work on empty alpha pixels around irregular silhouettes such as trees and suffer double- or triple-image ghosting when barycentric weights blend three neighboring atlas views.\n\n**Tight silhouette strips:** During the 64-view octahedral bake, each view's alpha silhouette is quantized into 8 horizontal strips whose 4-bit left and right bounds pack tightly into two `uint32` words per view. At runtime, the vertex shader unpacks the strip bounds for the three active octahedral views and merges their union directly on an 8-strip mesh, collapsing empty quad corners and eliminating trunk seams between adjacent strips.\n\n**Per-fragment depth parallax:** Instead of interpolating view vectors per vertex, every fragment casts the exact camera ray against each view's frame plane, reads baked depth dilated past the silhouette edge, and steps along the ray onto the reconstructed surface point. Because all three views reproject onto the same 3D surface position before blending, cross-view ghosting vanishes. Texture mip levels are chosen from the unshifted UVs so depth discontinuities never trigger coarse mip halos along foliage edges.",
 "when_to_use": "Choose it for dense open-world forests and irregular foliage silhouettes in WebGL2, WebGPU, or desktop engines where plain billboard quads cause heavy alpha overdraw and classic 3-view octahedral blending produces visible ghosting.\n\nPrefer [octahedral-impostors](octahedral-impostors) when rendering convex rocks or props whose quad fill ratio is already high and minimal vertex complexity matters most. Prefer [meshlets](meshlets) or [nanite-virtualized-geometry](nanite-virtualized-geometry) for mid-range trees that still need true silhouette deformation and close-up inspection. Pair with [gpu-driven-rendering](gpu-driven-rendering) to switch thousands of distant trees into instanced 8-strip draws.",
 "cost": {
  "class": "cheap",
  "notes": "8 horizontal strips (16 triangles) per instance with two uint32 bitmask reads in the vertex shader and three depth-parallaxed atlas lookups per covered fragment; substantially lower alpha overdraw than full-quad impostors."
 },
 "failure_modes": [
  "Single-layer baked depth cannot represent deep multi-layered canopy self-occlusion at extreme grazing angles",
  "Undilated depth buffers leak background depth along silhouette edges unless depth dilation is applied during atlas baking",
  "Sampling mipmaps from depth-shifted UVs causes derivative spikes and blocky mip seams unless LOD is evaluated from unshifted UVs",
  "Tight 4-bit strip bounds must be merged conservatively across all three active views to prevent clipping branches mid-transition"
 ],
 "sources": [
  {
   "role": "primary",
   "key": "url:https://kvyverse.com/octahedral-tree-impostors",
   "type": "web",
   "title": "Octahedral Tree Impostors with Depth Parallax and Silhouette Strips",
   "authors": [
    "Vlad Krutenyuk"
   ],
   "year": 2026,
   "venue": "kvyverse",
   "url": "https://kvyverse.com/octahedral-tree-impostors",
   "ids": {},
   "license": null,
   "extra": {
    "http_status": 200,
    "live": true,
    "archive": {
     "url": "http://web.archive.org/web/20261129003738/https://kvyverse.com/octahedral-tree-impostors",
     "timestamp": "20261129003738"
    },
    "page_title": null,
    "host": "kvyverse.com",
    "title_confirmed_by_page": false,
    "title_unconfirmed": false
   },
   "provenance": {
    "title": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "url": {
     "authority": "http",
     "endpoint": "GET https://kvyverse.com/octahedral-tree-impostors → 200",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "authors": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "venue": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "year": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-30T18:01:53.730Z",
   "title_sim": null,
   "__bib": "krutenyuk2026octahedralb"
  },
  {
   "role": "implementation",
   "key": "url:https://kvyverse.com/editor/world/6b0041d2e78fe5de949e5722",
   "type": "web",
   "title": "Octahedral Tree Impostors Live Source (Three.js)",
   "authors": [
    "Vlad Krutenyuk"
   ],
   "year": 2026,
   "venue": "kvyverse Editor",
   "url": "https://kvyverse.com/editor/world/6b0041d2e78fe5de949e5722",
   "ids": {},
   "license": null,
   "extra": {
    "http_status": 200,
    "live": true,
    "archive": null,
    "page_title": null,
    "host": "kvyverse.com",
    "title_confirmed_by_page": false,
    "title_unconfirmed": false
   },
   "provenance": {
    "title": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "url": {
     "authority": "http",
     "endpoint": "GET https://kvyverse.com/editor/world/6b0041d2e78fe5de949e5722 → 200",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "authors": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "venue": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "year": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-30T18:01:53.730Z",
   "title_sim": null,
   "__bib": "krutenyuk2026octahedral"
  },
  {
   "role": "tutorial",
   "key": "url:https://shaderbits.com/blog/octahedral-impostors",
   "type": "tutorial",
   "title": "Octahedral Impostors",
   "authors": [
    "Ryan Brucks"
   ],
   "year": null,
   "venue": "shaderbits.com",
   "url": "https://shaderbits.com/blog/octahedral-impostors",
   "ids": {},
   "license": null,
   "extra": {
    "http_status": 200,
    "live": true,
    "archive": {
     "url": "http://web.archive.org/web/20261113064542/https://shaderbits.com/blog/octahedral-impostors",
     "timestamp": "20261113064542"
    },
    "page_title": "Post Page",
    "host": "shaderbits.com",
    "title_confirmed_by_page": false,
    "title_unconfirmed": true
   },
   "provenance": {
    "title": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "url": {
     "authority": "http",
     "endpoint": "GET https://shaderbits.com/blog/octahedral-impostors → 200",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "authors": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "venue": {
     "authority": "http",
     "endpoint": "GET https://shaderbits.com/blog/octahedral-impostors → 200",
     "checked_at": "2026-11-30T18:01:53.730Z"
    },
    "year": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-30T18:01:53.730Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-30T18:01:53.730Z",
   "title_sim": 0,
   "__bib": "brucksoctahedral"
  }
 ],
 "presets": [
  {
   "id": "silhouette-strip-octahedral-impostors-live",
   "title": "Silhouette-Strip Octahedral Impostors — full alpha-quad overdraw & ghosting (left) vs 8-strip silhouette + depth parallax (right)",
   "runtime": "glsl-fragment",
   "params": {
    "P_PARALLAX": 0.8,
    "P_OVERDRAW_VIS": 0.65,
    "P_ORBIT": 0.55,
    "P_SPLIT": 0.48
   },
   "basis": "original",
   "license_note": "MIT — written for this index.",
   "code": "const float P_PARALLAX = 0.80; // P Ray Depth Parallax [0.0, 1.0, 0.05]\nconst float P_OVERDRAW_VIS = 0.65; // P Overdraw Mask Vis [0.0, 1.0, 0.05]\nconst float P_ORBIT = 0.55; // P Orbit Speed [0.0, 1.5, 0.05]\nconst float P_SPLIT = 0.48; // P Naive Quad / Strips [0.0, 1.0, 0.02]\n\nvec2 rot2(vec2 p, float a) {\n  float c = cos(a);\n  float s = sin(a);\n  return vec2(c * p.x - s * p.y, s * p.x + c * p.y);\n}\n\n// Irregular botanical-tree crown + trunk SDF (high transparent alpha waste on a bounding quad!)\nvec2 mapTree(vec3 p) {\n  // Trunk\n  vec2 tr = vec2(length(p.xz) - mix(0.085, 0.045, clamp((p.y + 0.48) * 1.4, 0.0, 1.0)), abs(p.y + 0.22) - 0.28);\n  float dTrunk = length(max(tr, 0.0)) + min(max(tr.x, tr.y), 0.0);\n  vec2 res = vec2(dTrunk, 1.0);\n\n  // Asymmetric multi-lobe canopy spheres\n  float d1 = length(p - vec3(0.0, 0.18, 0.0)) - 0.24;\n  float d2 = length(p - vec3(-0.22, 0.06, 0.08)) - 0.17;\n  float d3 = length(p - vec3(0.20, 0.10, -0.06)) - 0.18;\n  float d4 = length(p - vec3(0.04, 0.34, 0.05)) - 0.15;\n  float d5 = length(p - vec3(-0.10, 0.24, -0.14)) - 0.15;\n  float dCanopy = min(min(d1, d2), min(min(d3, d4), d5));\n  // Subtle foliage bump\n  dCanopy += 0.015 * sin(p.x * 26.0) * sin(p.y * 26.0) * sin(p.z * 26.0);\n  if (dCanopy < res.x) res = vec2(dCanopy, 2.0);\n  return res;\n}\n\nvec3 shadeTreeRay(vec3 ro, vec3 rd, out float hitA, out float hitD) {\n  hitA = 0.0;\n  hitD = 10.0;\n  float t = 0.1;\n  vec2 h = vec2(10.0, 0.0);\n  for (int i = 0; i < 48; i++) {\n    vec2 m = mapTree(ro + rd * t);\n    if (m.x < 0.003) { h = vec2(t, m.y); break; }\n    t += m.x * 0.85;\n    if (t > 4.5) break;\n  }\n  if (h.y < 0.5) return vec3(0.0);\n  hitA = 1.0;\n  hitD = h.x;\n  vec3 p = ro + rd * h.x;\n  vec2 e = vec2(0.004, 0.0);\n  vec3 n = normalize(vec3(\n    mapTree(p + e.xyy).x - mapTree(p - e.xyy).x,\n    mapTree(p + e.yxy).x - mapTree(p - e.yxy).x,\n    mapTree(p + e.yyx).x - mapTree(p - e.yyx).x\n  ));\n  vec3 lDir = normalize(vec3(0.62, 0.78, 0.45));\n  float ndl = max(dot(n, lDir), 0.0);\n  vec3 alb = (h.y < 1.5) ? vec3(0.38, 0.24, 0.15) : mix(vec3(0.16, 0.48, 0.22), vec3(0.46, 0.78, 0.28), 0.5 + 0.5 * n.y);\n  return alb * (0.28 + 0.95 * ndl) + vec3(0.18, 0.30, 0.45) * (0.5 + 0.5 * n.y) * 0.35;\n}\n\nvec3 aces(vec3 x) {\n  x = max(x, 0.0);\n  return (x * (2.51 * x + 0.03)) / (x * (2.43 * x + 0.59) + 0.14);\n}\n\nvoid mainImage(out vec4 fragColor, in vec2 fragCoord) {\n  vec2 uv = (fragCoord - 0.5 * iResolution.xy) / iResolution.y;\n  float screenX = fragCoord.x / max(iResolution.x, 1.0);\n  float split = clamp(P_SPLIT, 0.0, 1.0);\n  float parallax = clamp(P_PARALLAX, 0.0, 1.0);\n  float overVis = clamp(P_OVERDRAW_VIS, 0.0, 1.0);\n  float ang = iTime * max(P_ORBIT, 0.0) * 0.65;\n\n  // Orbiting camera around the impostor asset\n  vec3 ro = vec3(1.85 * sin(ang), 0.18, 1.85 * cos(ang));\n  vec3 fwd = normalize(-ro);\n  vec3 right = normalize(cross(fwd, vec3(0.0, 1.0, 0.0)));\n  vec3 up = cross(right, fwd);\n  vec3 rd = normalize(fwd * 1.48 + right * uv.x + up * uv.y);\n\n  vec3 bg = mix(vec3(0.06, 0.09, 0.15), vec3(0.18, 0.27, 0.42), smoothstep(-0.4, 0.5, uv.y));\n  vec3 col = bg;\n\n  // Bounding billboard quad region in screen space [-0.34, 0.34] x [-0.38, 0.38]\n  bool inQuad = (abs(uv.x) < 0.34 && abs(uv.y) < 0.38);\n\n  if (screenX < split) {\n    // Left: Naive single-quad octahedral impostor -- suffers wasted transparent overdraw across entire quad\n    // AND double/triple-view barycentric ghosting between adjacent octahedral atlas angles!\n    float a1, d1, a2, d2;\n    float snapAng = floor(ang * 4.0) / 4.0;\n    float nextAng = snapAng + 0.25;\n    float blendW = fract(ang * 4.0);\n\n    vec3 ro1 = vec3(1.85 * sin(snapAng), 0.18, 1.85 * cos(snapAng));\n    vec3 f1 = normalize(-ro1), r1 = normalize(cross(f1, vec3(0.0, 1.0, 0.0))), u1 = cross(r1, f1);\n    vec3 c1 = shadeTreeRay(ro1, normalize(f1 * 1.48 + r1 * uv.x + u1 * uv.y), a1, d1);\n\n    vec3 ro2 = vec3(1.85 * sin(nextAng), 0.18, 1.85 * cos(nextAng));\n    vec3 f2 = normalize(-ro2), r2 = normalize(cross(f2, vec3(0.0, 1.0, 0.0))), u2 = cross(r2, f2);\n    vec3 c2 = shadeTreeRay(ro2, normalize(f2 * 1.48 + r2 * uv.x + u2 * uv.y), a2, d2);\n\n    vec3 ghostCol = mix(c1, c2, blendW);\n    float ghostA = mix(a1, a2, blendW);\n\n    // Highlight wasted transparent quad pixels in crimson overdraw tint\n    if (inQuad) {\n      vec2 qEdge = abs(uv) - vec2(0.34, 0.38);\n      float border = smoothstep(0.012, 0.002, abs(max(qEdge.x, qEdge.y)));\n      col = mix(col, vec3(0.95, 0.22, 0.30), (1.0 - ghostA) * overVis * 0.32);\n      col = mix(col, vec3(1.0, 0.42, 0.48), border * overVis * 0.85);\n    }\n    col = mix(col, ghostCol, ghostA);\n  } else {\n    // Right: Tight 8-strip bit-packed silhouette mesh + per-fragment camera-ray depth parallax (zero ghosting!)\n    float aExact, dExact;\n    vec3 cExact = shadeTreeRay(ro, rd, aExact, dExact);\n\n    // Visualize the tight 8 horizontal bit-packed silhouette strips hugging the tree outline (cutting ~65% overdraw!)\n    if (inQuad) {\n      float stripIdx = floor((uv.y + 0.38) / 0.76 * 8.0);\n      float stripY = (stripIdx + 0.5) / 8.0 * 0.76 - 0.38;\n      // Tight per-strip half-width matching trunk vs canopy silhouette\n      float stripHalfW = (stripIdx < 2.5) ? 0.095 : (stripIdx < 6.5 ? 0.295 : 0.165);\n      bool inStrip = abs(uv.x) < stripHalfW;\n      float stripEdgeX = smoothstep(0.010, 0.002, abs(abs(uv.x) - stripHalfW));\n      float stripEdgeY = smoothstep(0.008, 0.002, abs(fract((uv.y + 0.38) / 0.76 * 8.0) - 0.5) * 0.095 - 0.044);\n      if (inStrip) {\n        col = mix(col, vec3(0.16, 0.88, 0.96), (1.0 - aExact) * overVis * 0.14);\n        col = mix(col, vec3(0.20, 0.96, 0.82), clamp(stripEdgeX + stripEdgeY, 0.0, 1.0) * overVis * 0.55);\n      }\n    }\n    // Depth-parallax blends smoothly into exact ray intersection (eliminates multi-view ghosting!)\n    float aSnap, dSnap;\n    float snapAng = floor(ang * 4.0) / 4.0;\n    vec3 ro1 = vec3(1.85 * sin(snapAng), 0.18, 1.85 * cos(snapAng));\n    vec3 f1 = normalize(-ro1), r1 = normalize(cross(f1, vec3(0.0, 1.0, 0.0))), u1 = cross(r1, f1);\n    vec3 cSnap = shadeTreeRay(ro1, normalize(f1 * 1.48 + r1 * uv.x + u1 * uv.y), aSnap, dSnap);\n\n    vec3 finalTree = mix(cSnap, cExact, parallax);\n    float finalA = mix(aSnap, aExact, parallax);\n    col = mix(col, finalTree, finalA);\n  }\n\n  float sep = smoothstep(0.0035, 0.0008, abs(screenX - split));\n  col = mix(col, vec3(0.95, 0.98, 1.0), sep);\n  fragColor = vec4(pow(clamp(aces(col), 0.0, 1.0), vec3(1.0 / 2.2)), 1.0);\n}",
   "execution_fidelity": "conceptual-diagram",
   "proof": {
    "kind": "rendered",
    "label": "rendered 2026-11-30",
    "ok": true,
    "proof": {
     "ok": true,
     "technique": "silhouette-strip-octahedral-impostors",
     "runtime": "glsl-fragment",
     "checked_at": "2026-11-30T21:07:25.000Z",
     "renderer": "Headless EGL Tesla T4/PCIe/SSE2, OpenGL 3.30 Core, 512×512, iTime=1.5",
     "stats": {
      "mean": 0.5689,
      "std": 0.1523,
      "min": 0.3258,
      "max": 0.9014
     },
     "image": "/specimens/silhouette-strip-octahedral-impostors-live.webp",
     "reason": null
    }
   }
  }
 ],
 "related": [
  "octahedral-impostors",
  "gpu-driven-rendering",
  "foliage-wind-animation",
  "meshlets"
 ],
 "extends": [
  "octahedral-impostors"
 ],
 "supersedes": [],
 "combines_with": [
  {
   "id": "gpu-driven-rendering",
   "why": "GPU frustum and Hi-Z culling routes distant forest instances into indirect 8-strip impostor draws."
  },
  {
   "id": "foliage-wind-animation",
   "why": "Subtle vertex sway on the upper silhouette strips blends distant tree impostors seamlessly with nearby animated canopy meshes."
  }
 ],
 "provenance": {
  "prose": "original text written for this index (research draft, editorially reviewed)",
  "sources_verified_at": "2026-11-30T18:01:53.730Z",
  "draft": "data/drafts/performance/silhouette-strip-octahedral-impostors.json"
 },
 "solves": [
  "octahedral tree impostor ghosting between three blended views",
  "reduce alpha overdraw on distant billboard trees with silhouette strips",
  "gta 6 style octahedral impostors with depth parallax in threejs",
  "fix impostor trunk seams and coarse mip halos at depth edges",
  "pack 8 silhouette strip bounds into two uints in vertex shader"
 ],
 "authority": "Krutenyuk, 2026",
 "url": "https://texelatlas.vercel.app/t/silhouette-strip-octahedral-impostors/",
 "execution_fidelity": "conceptual-diagram",
 "fidelity_label": "Visual Diagram",
 "benchmark_eligible": false,
 "gpu_weight": {
  "weight_x": 27.77,
  "tier": "heavy",
  "p50_ms": 0.9135,
  "p95_ms": 0.9563,
  "baseline_p50_ms": 0.0329,
  "gpu": "Tesla T4/PCIe/SSE2",
  "resolution": "1920x1080",
  "method": "opengl-timer-query",
  "frames": 32,
  "preset_id": "silhouette-strip-octahedral-impostors-live",
  "execution_fidelity": "conceptual-diagram",
  "fidelity_label": "Visual Diagram",
  "benchmark_eligible": false,
  "generated_at": "2026-11-30T21:07:47Z",
  "l4": {
   "weight_x": 25.45,
   "tier": "heavy",
   "p50_ms": 0.4047,
   "p95_ms": 0.415,
   "speedup_x": 2.26,
   "gpu": "NVIDIA L4/PCIe/SSE2",
   "resolution": "1920x1080",
   "baseline_p50_ms": 0.0159
  },
  "a100": {
   "weight_x": 18.62,
   "tier": "moderate",
   "p50_ms": 0.5363,
   "p95_ms": 0.5451,
   "speedup_x": 1.7,
   "gpu": "NVIDIA A100-SXM4-40GB/PCIe/SSE2",
   "resolution": "1920x1080",
   "baseline_p50_ms": 0.0288
  }
 }
}