feat(geo-layers): coverage LOD tile prefetching#10306
Conversation
chrisgervang
left a comment
There was a problem hiding this comment.
There are a couple of interesting things in the demo that I'm not really sure how to improve:
- As the low-resolution tiles are loading in and the high-resolution tiles are loading on top, I can see almost like a parallax or perspective shift between the low-res and high-res tiles. I'm curious what the root cause of that is.
- I see a lot of z-fighting as we zoom into the final destination in New York between the low-res and high-res tiles. There's a lot of z-fighting in the before as well, so this isn't a regression and more a limitation with our renderer
I wrote a draft of docs for this that I'll push up for you to review.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 4be9e53. Configure here.
| // Some viewport/tile combinations are not projectable. Keep them valid but lowest priority. | ||
| } | ||
| return Number.MAX_SAFE_INTEGER; | ||
| } |
There was a problem hiding this comment.
Unprojectable tiles break priority tier boundaries
Medium Severity
_getTileDistanceSquared returns Number.MAX_SAFE_INTEGER (~9e15) when a tile's bounding box can't be fully projected (fewer than 4 finite screen corners or a caught exception). This value, when added to SELECTED_TILE_PRIORITY (0), produces a priority of ~9e15, far exceeding PREFETCH_TILE_PRIORITY (~4.2e9 max). Since lower priority values load first, an unprojectable selected tile loads after all prefetch and visible tiles, violating the intended tier system. This is particularly likely in pitched globe views—exactly the target use case—where horizon tiles may not project cleanly.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 4be9e53. Configure here.
Almost certain this is a
Yeah it resolves ever-so-slightly faster in the new strategy due to the center priority, but its nowhere near as bad when testing with the |
1321c68 to
149a855
Compare
a32e93b to
2b5d3cc
Compare


lod_strategy_comparison.mov
Summary
Adds opt-in coverage LOD prefetching for TileLayer/TerrainLayer so animated transitions can keep coarse coverage available while high-resolution target tiles load.
Why
During fast camera transitions, high-resolution requests can saturate the queue and leave temporary blank coverage. Prefetching ancestor tiles gives the viewport useful lower-resolution coverage, then lets sharper selected tiles replace it as they arrive.
Change
Validation
Split Notes
The center-priority/default request ordering and public getPriority accessor were moved to the independent PR #10364. This PR is now scoped to lodStrategy coverage prefetching only.