Your browser sucks, JavaScript disabled! Gunnar's console needs JavaScript and WebAssembly. Git over SSH on port 2222 does not.

nordisk/facett

facett-map3d-flight/.nornir/assets/cdlod-terrain.svg

<svg xmlns="http://www.w3.org/2000/svg" width="900" height="380" viewBox="0 0 900 380" font-family="monospace" font-size="12">
  <rect width="900" height="380" fill="#0e1116"/>
  <text x="20" y="30" fill="#e6edf3" font-size="15" font-weight="bold">facett-map3d-flight · CDLOD terrain quadtree (roadmap §6)</text>

  <defs>
    <marker id="a" markerWidth="9" markerHeight="9" refX="7" refY="3" orient="auto">
      <path d="M0 0 L7 3 L0 6 z" fill="#6fd3f5"/>
    </marker>
  </defs>

  <!-- selection pipeline -->
  <g stroke="#6fd3f5" fill="#12313a">
    <rect x="20"  y="70"  width="150" height="56" rx="6"/>
    <rect x="215" y="70"  width="170" height="56" rx="6"/>
    <rect x="430" y="70"  width="160" height="56" rx="6"/>
    <rect x="635" y="70"  width="160" height="56" rx="6"/>
  </g>
  <g fill="#e6edf3" text-anchor="middle">
    <text x="95"  y="92">camera WorldPos</text><text x="95"  y="110" fill="#8fb3c0">f64 ground pos</text>
    <text x="300" y="92">Cdlod::select</text><text x="300" y="110" fill="#8fb3c0">quadtree · by distance</text>
    <text x="510" y="92">SelectedNode[]</text><text x="510" y="110" fill="#8fb3c0">region · level · morph</text>
    <text x="715" y="92">build_terrain_mesh</text><text x="715" y="110" fill="#8fb3c0">drape (REUSED)</text>
  </g>
  <g stroke="#6fd3f5" fill="none" marker-end="url(#a)">
    <line x1="170" y1="98" x2="211" y2="98"/>
    <line x1="385" y1="98" x2="426" y2="98"/>
    <line x1="590" y1="98" x2="631" y2="98"/>
  </g>

  <!-- CDLOD rules -->
  <rect x="215" y="160" width="375" height="72" rx="6" stroke="#f2b84b" fill="#2a2410"/>
  <text x="402" y="182" fill="#f2b84b" text-anchor="middle" font-weight="bold">the two invariants (crack-free)</text>
  <text x="402" y="200" fill="#e6edf3" text-anchor="middle">range(level) = leaf_range · ratio^level</text>
  <text x="402" y="216" fill="#8fb3c0" text-anchor="middle">adjacent nodes differ by ≤1 level · areas tile exactly</text>
  <path d="M300 126 L340 158" stroke="#f2b84b" fill="none" marker-end="url(#a)"/>

  <!-- morph -->
  <rect x="635" y="160" width="160" height="72" rx="6" stroke="#8fd18f" fill="#132a13"/>
  <text x="715" y="182" fill="#8fd18f" text-anchor="middle" font-weight="bold">morph_factor</text>
  <text x="715" y="200" fill="#e6edf3" text-anchor="middle">0 near → 1 at edge</text>
  <text x="715" y="216" fill="#8fb3c0" text-anchor="middle">no LOD popping</text>
  <path d="M510 126 L560 158" stroke="#8fd18f" fill="none" stroke-dasharray="4 3"/>

  <!-- quadtree picture -->
  <g stroke="#6fd3f5" fill="none">
    <rect x="20" y="255" width="120" height="120"/>
    <line x1="80" y1="255" x2="80" y2="375"/><line x1="20" y1="315" x2="140" y2="315"/>
    <!-- subdivide the near (SW) quadrant -->
    <rect x="20" y="315" width="60" height="60"/>
    <line x1="50" y1="315" x2="50" y2="375"/><line x1="20" y1="345" x2="80" y2="345"/>
  </g>
  <circle cx="35" cy="360" r="4" fill="#f2b84b"/>
  <text x="150" y="300" fill="#8fb3c0" font-size="11">camera (●) near a corner → that</text>
  <text x="150" y="316" fill="#8fb3c0" font-size="11">quadrant subdivides to the finest leaf;</text>
  <text x="150" y="332" fill="#8fb3c0" font-size="11">far quadrants stay one coarse node.</text>

  <!-- GPU seam -->
  <rect x="430" y="270" width="365" height="52" rx="6" stroke="#c9a0ff" fill="#1c1630"/>
  <text x="612" y="291" fill="#c9a0ff" text-anchor="middle" font-weight="bold">GPU height-morph (cdlod_morph.wgsl) — adapter-guarded</text>
  <text x="612" y="308" fill="#8fb3c0" text-anchor="middle">cs_morph readback == CPU morph_height oracle · self-skips w/ sentinel</text>

  <text x="20" y="360" fill="#7f8b98" font-size="11"></text>
  <text x="150" y="366" fill="#7f8b98" font-size="10">CPU selection math is RED-when-broken tested GPU-less; the 21-pass pipeline is untouched (L2 additive).</text>
</svg>