Written by Claude on behalf of @kylebarron
Context
In the globe-view prototype (#563, part of #82), tile LOD uses the Web Mercator getMetersPerPixel(lat, zoom) model evaluated at the tile's center latitude (packages/deck.gl-raster/src/raster-tileset/raster-tile-traversal.ts).
Problem
That model is exact at the view center but ignores globe limb foreshortening: tiles near the globe's edge appear compressed on screen yet are assigned the same LOD as if they were at the view center, so they over-fetch (more detail than needed — never under-fetch). Functionally fine, but wasteful.
Fix
Use a camera-aware screen-space-error metric: project the tile's bounding volume to screen, measure its pixel span vs. the tile's source pixel dimensions, and drive LOD off that. This handles foreshortening directly and would also subsume the mercator-latitude approximation.
This overlaps the spherical-reprojection accuracy work (#563 follow-up) and could be tackled together.
Links
Context
In the globe-view prototype (#563, part of #82), tile LOD uses the Web Mercator
getMetersPerPixel(lat, zoom)model evaluated at the tile's center latitude (packages/deck.gl-raster/src/raster-tileset/raster-tile-traversal.ts).Problem
That model is exact at the view center but ignores globe limb foreshortening: tiles near the globe's edge appear compressed on screen yet are assigned the same LOD as if they were at the view center, so they over-fetch (more detail than needed — never under-fetch). Functionally fine, but wasteful.
Fix
Use a camera-aware screen-space-error metric: project the tile's bounding volume to screen, measure its pixel span vs. the tile's source pixel dimensions, and drive LOD off that. This handles foreshortening directly and would also subsume the mercator-latitude approximation.
This overlaps the spherical-reprojection accuracy work (#563 follow-up) and could be tackled together.
Links
dev-docs/coordinate-systems.md→ "Globe view" → "LOD gotcha" for the current approximation and why the latitude is read from the mercator-world bounds.