Skip to content

Terrain beautify: Iceland glacial grade + arid Grand Canyon (brown drainage, Colorado focal point)#97

Merged
AdaWorldAPI merged 4 commits into
mainfrom
claude/geo-dramatic-sky
Jul 8, 2026
Merged

Terrain beautify: Iceland glacial grade + arid Grand Canyon (brown drainage, Colorado focal point)#97
AdaWorldAPI merged 4 commits into
mainfrom
claude/geo-dramatic-sky

Conversation

@AdaWorldAPI

@AdaWorldAPI AdaWorldAPI commented Jul 8, 2026

Copy link
Copy Markdown
Owner

Aesthetic pass over the /garmin/<location> terrain scenes, driven by reference photos. Three commits, all shader- and bake-side (no route/server changes).

1. Beautiful-Iceland grade (b77da963)

Vivid Icelandic-highland look for the Iceland DEM scene, all in GeoHelix.tsx (no asset rebake):

  • Glacial-meltwater turquoise water, copper volcanic/desert rock, moss-by-aspect (moss favours the shaded/weather-facing slopes via dot(n,-sun), gated to Iceland by uMoss).
  • +22% saturation grade, warm sunset key + cool sky fill.
  • A tribonacci-lacunarity drifting cloud sky in the sky-dome fragment shader (decoupled from the 16M-vert mesh; throttled ~15fps).

2. Arid Grand Canyon — brown dry drainage, blue Colorado only (dab1b034)

The dendritic Stream network on the canyon is DRY drainage (washes/gullies), not water — river-blue made the plateau read as wet.

  • GeoKind::arid_palette() browns the Stream KIND ([120,68,44]); garmin_bake --arid applies it to the ONE palette that feeds both the ver-8 terrain KIND block and the DRP1 drape, so drainage browns consistently. The rebake diff is exactly the 3-byte Stream RGB in each wire — terrain geometry byte-identical to the deployed asset.
  • uArid shader uniform (1 = non-glacial scene) gates the glacial turquoise OFF so the canyon's Water stays plain river-blue (not teal); Iceland keeps its turquoise.

3. Colorado as focal point (cc6b1244)

The reference photos show the Colorado as the bold visual focal point; the first pass left it a ~1-cell hairline. Two correctness-shaped fixes:

  • Neatline exclusion — Garmin Poly type 0x4b is the background/definition-area rectangle (a 5-pt ring spanning 98%×99% of the tile), mis-classed as Water; its outline drew a blue border around the whole tile once the river was widened. Carve 0x4b → Other. Golden histogram updated (Water 2255→2251, Other 3664→3668).
  • River wideningterrain::dilate_kind() (tested) binary-dilates the Water cells ×2 on --arid so the river-fill reads as a ribbon (5802→13184 cells).
  • Luminous river shader — brighter arid-water base + a post-grade silvery river-blue lift so the warm key no longer mutes the river.

Verification

  • geo-hhtl lib: 24/24 tests green (arid palette, river dilation, updated histogram golden).
  • cockpit: tsc --noEmit clean, npm run build clean.
  • Headless /garmin/grand-canyon: warm desert plateau + rust-brown incised drainage, the Colorado a bold blue ribbon threading the canyon depth; tile-edge artifact gone (blue terrain fraction 0.46%→1.31%, interior). Iceland unaffected (uArid=0).
  • The improved canyon replaces the existing garmin: grand-canyon view in place — same menu entry, no new dropdown.
  • No changes under the crates/ cargo workspace; geo/ (separate workspace) and cockpit/ (vite app) verified with their own toolchains.

🤖 Generated with Claude Code

https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC


Generated by Claude Code

Summary by CodeRabbit

  • New Features
    • Added an arid map rendering mode that recolors dry stream beds while keeping real water features blue.
    • Improved river visibility in arid scenes by widening thin water lines and refining how the Colorado River is highlighted.
    • Enhanced terrain and sky visuals with new lighting, moss/lichen tinting, and more dynamic cloud rendering.
  • Bug Fixes
    • Corrected certain rectangular background polygons that were previously treated as water, improving map accuracy.

claude added 3 commits July 8, 2026 12:42
…copper rock, aspect moss, tribonacci cloud sky

Photoreference-driven aesthetic pass on the geo terrain + sky, chasing the vivid
aerial-Iceland look (turquoise glacial water, moss-green lee slopes, copper
volcanic rock, snow caps, a textured drifting cloudscape). All shader-side —
no asset rebake, decoupled from the mesh (the clouds live in the sky dome, so
they don't touch the 16 M terrain verts — LOD-irrelevant). Replaces the
per-vertex cloud-shadow term from #96 (the "fill 12 M verts with shadows"
approach the operator rejected).

Terrain shader (KIND/aspect-gated so each scene keeps its own identity):
- TURQUOISE water — blue-KIND cells pushed to a vivid glacial-meltwater teal
  ("as turquoise as it gets"). Only Iceland's ocean/rivers change; the canyon
  has no water KIND.
- COPPER rock — the height ramp's rock/scree bands go copper/rust instead of
  neutral-brown/grey. Works for BOTH scenes (Iceland volcanic + Grand Canyon
  red rock).
- MOSS by ASPECT — moss/lichen favours the shaded, weather-facing slopes (the
  "north face holds the moisture" rule; ~ aspect × insolation via dot(n,-sun)),
  bare copper rock on the sun-baked faces — the mottled green/copper of the
  reference. Gated by a uMoss uniform to Iceland; the desert canyon stays bare.
- VIVID GRADE — a measured +22% saturation + gentle contrast so each scene
  punches its own aColor palette (Iceland greens/turquoise pop, the canyon
  deepens to rich red — not radioactive, not green).
- Sun-glint (now on turquoise water) + ice sheen retained, KIND-gated.

Sky dome:
- Dramatic DRIFTING CLOUDS — the flat gradient becomes a textured cloudscape.
  The fBm uses the TRIBONACCI constant (≈1.8393) as its octave lacunarity, so
  successive octaves never fall on a repeating lattice → organic, non-repeating
  clouds (the number-theoretic cousin of the workspace's golden-spiral ruler).
  Drifts with uTime, throttled to ~15 fps for all geo scenes.

Verified by render (static capture; the animated 16.5 M scene needs a real GPU):
Iceland reads as vivid aerial highlands (green lee slopes, copper rock, turquoise
sea, snow, cloudy sky); the canyon reads as rich red-rock desert with turquoise
rivers + cloud sky and NO false moss. tsc --noEmit clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC
The dendritic Stream network on the canyon tile is DRY drainage (washes /
gullies / arroyos), not water — river-blue made the plateau read as wet.
Reserve blue for the actual Water bodies (the Colorado) and recolour the
drainage rust-brown, so the river stays the visual focal point.

- geo classify.rs: GeoKind::ARID_DRAINAGE = [120,68,44] + arid_palette() —
  the KIND palette with Stream browned, every other class (incl. blue Water)
  unchanged. Unit-tested (drainage warm, water stays blue-dominant).
- geo garmin_bake.rs: --arid uses arid_palette() for the ONE palette that
  feeds both the ver-8 terrain KIND block AND the DRP1 drape, so the drainage
  browns consistently across terrain overlay + line network. The diff vs the
  non-arid bake is exactly the 3-byte Stream RGB entry in each wire; the
  terrain geometry is byte-identical to the deployed asset.
- cockpit GeoHelix.tsx: uArid uniform (1 = non-glacial scene) gates the
  glacial turquoise OFF (the canyon's Water stays plain river-blue, not teal)
  and re-asserts a clean deep river-blue for the Water cells so the Colorado
  survives the 55% terrain blend + warm sunset key as the focal point.
  Iceland (uArid=0) keeps its meltwater turquoise; browned drainage is wet=0
  so the shader leaves it as baked earth.
- Rebaked canyon.v8grid{,.drape}.soa.gz from 47505316.img --arid. Headless
  /garmin/grand-canyon verified: warm desert plateau + brown incised drainage,
  the Colorado a thin blue ribbon in the canyon depth (0 → 475 blue water px).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC
… river

The drainage-brown pass left the Colorado a ~1-cell hairline; the reference
photos show it as the bold visual focal point. Two correctness-shaped fixes:

- classify.rs: Garmin Poly type 0x4b is the background / definition-area
  rectangle (a 5-point ring spanning 98%×99% of the tile), not water — it drew
  a blue border around the whole tile once the river was widened. Carve
  0x4b → Other (before the 0x3c..=0x4f → Water range). Golden histogram
  updated: Water 2255→2251, Other 3664→3668 (the 4 reclassified 0x4b polys).
- terrain.rs: dilate_kind() (tested) binary-dilates a KIND by N rings;
  garmin_bake --arid widens the Water cells ×2 so the Colorado's thin
  river-fill reads as a ribbon (5802→13184 cells). Real lakes/tanks widen too
  — still discrete blue dots, not a wet plateau.
- GeoHelix.tsx: brighter arid-water base (0.16,0.44,0.66) + a post-grade
  silvery river-blue lift (step 7, wet·uArid·0.55) so the warm sunset key no
  longer mutes the river; it catches the light as the focal point.
- Rebaked canyon.v8grid{,.drape}.soa.gz. Verified /garmin/grand-canyon: the
  Colorado threads the canyon as a bold blue ribbon, plateau clean earth with
  brown drainage, tile-edge artifact gone (blue terrain fraction 0.46%→1.31%,
  interior).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC
@coderabbitai

coderabbitai Bot commented Jul 8, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@AdaWorldAPI, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 39 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 16a76786-15c3-4282-8c92-deb942f8602f

📥 Commits

Reviewing files that changed from the base of the PR and between cc6b124 and fd2ff1a.

📒 Files selected for processing (1)
  • cockpit/src/GeoHelix.tsx
📝 Walkthrough

Walkthrough

Adds an "arid" terrain mode: GeoKind::arid_palette() recolors Stream drainage while keeping Water blue, reclassifies Garmin polygon type 0x4b from Water to Other, adds a dilate_kind grid-dilation helper used via a new --arid flag in garmin_bake, reworks GeoHelix shaders (uMoss/uArid uniforms, sky clouds), and updates plan docs.

Changes

Arid Drainage and River Rendering

Layer / File(s) Summary
GeoKind arid palette and neatline reclassification
geo/src/garmin/classify.rs
Adds ARID_DRAINAGE constant and arid_palette() recoloring Stream while preserving Water; reclassifies polygon type 0x4b from Water to Other; updates tests and golden histogram counts.
Kind grid dilation helper
geo/src/garmin/terrain.rs
Adds dilate_kind performing repeated 4-neighbourhood dilation of a tag over a grid, with a unit test verifying river-widening behavior.
garmin_bake --arid flag wiring
geo/src/bin/garmin_bake.rs
Adds --arid CLI flag, dilates Water cells in the KIND grid when enabled, and selects arid_palette() for ver-8 encoding.
GeoHelix shader updates for arid/moss terrain and sky clouds
cockpit/src/GeoHelix.tsx
Adds uMoss/uArid uniforms, reworks vertex shader water/moss coloring, replaces sky dome shader with noise-based clouds, and drives uTime on the sky material.
Plan documentation updates
claude-notes/plans/2026-07-08-osm-garmin-drape.md
Documents the arid drainage recolor and Colorado focal-point fixes (neatline exclusion, river dilation, shader brightening).

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

  • AdaWorldAPI/q2#92: Also modifies cockpit/src/GeoHelix.tsx's geo-scene/sky rendering, which this PR further rewrites for terrain uniforms and sky dome shaders.

Poem

A river once thin, now brown and now wide,
The rabbit hops rocks on the arid hillside,
Streams turn to rust while the Colorado stays blue,
Clouds drift on high with a shader that's new,
Dilate, recolor, and bake it once more,
Hop, hop, hooray for the desert-tinged floor! 🐇🏜️

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly reflects the main visual updates to Iceland and the arid Grand Canyon, including brown drainage and Colorado emphasis.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Warning

Review ran into problems

🔥 Problems

Git: Failed to clone repository. Please run the @coderabbitai full review command to re-trigger a full review. If the issue persists, set path_filters to include or exclude specific files.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cursor

cursor Bot commented Jul 8, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_29303452-0f1c-4b30-a4d1-d30dece21a7f)

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cc6b124464

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread cockpit/src/GeoHelix.tsx Outdated
// the continuous redraw of a heavy DEM so it's cheap on battery). Anatomy/buildings
// never enter this branch and stay fully on-demand (no idle cost).
if (isTerrainScene && tnow - lastCloud >= 66) { lastCloud = tnow; uniforms.uTime.value = (tnow - t0) * 0.001; dirty.current = true; }
if (skyMat && tnow - lastCloud >= 66) { lastCloud = tnow; skyMat.uniforms.uTime.value = (tnow - t0) * 0.001; dirty.current = true; }

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Gate cloud redraws to terrain scenes

When viewing the OSM/building geo scene (/geo or ?scene=osm), skyMat is non-null because the sky dome is created for any geo scene, while isTerrainScene is false. This condition now wakes the render loop every ~66 ms and redraws the whole building scene at idle, defeating the on-demand rendering path immediately below; if the continuous cloud animation is only meant for terrain DEMs, keep this gated on the terrain scene rather than the presence of a sky material.

Useful? React with 👍 / 👎.

The drifting-cloud tick was gated on `skyMat` being non-null, but the sky
dome is created for ANY geo scene — including the OSM/building `/geo` scene
(isGeoScene, not isTerrainScene). That woke the render loop every ~66 ms and
redrew the heavy 6.8 M-tri building scene at idle, defeating the on-demand
render path directly below and the block comment's own claim that
"anatomy/buildings never enter this branch".

Gate on `isTerrainScene && skyMat` so only the terrain DEM scenes (Iceland,
Grand Canyon) advance the cloud drift; the OSM scene keeps a static cloud sky
(uTime stays 0) and returns to idle-cheap on-demand rendering.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC
@AdaWorldAPI AdaWorldAPI merged commit 845e4a5 into main Jul 8, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants