Repository navigation
refactor: rely on deck.gl 9.4 for center-first tile loading - #669
Merged
Merged
Conversation
Since deck.gl 9.4, Tileset2D prioritizes tile requests by screen distance
from the viewport center, so our own center-out sorts in RasterTileset2D
and MosaicTileset2D are redundant. Remove them, along with the
sort-by-distance helper and its internal cross-package export.
deck.gl only reads `{west, south, east, north}` tile bboxes, so
MosaicTileset2D now returns that shape from getTileMetadata instead of an
array. That also lets mosaic tiles pass deck.gl's cull-rect visibility
check, which previously dropped every mosaic tile from picking.
MosaicSource.bbox is unchanged.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
kylebarron
commented
Sep 23, 2026
kylebarron
enabled auto-merge (squash)
September 23, 2026 20:56
willjnz
added a commit
to willjnz/deck.gl-raster
that referenced
this pull request
Sep 29, 2026
…istic work) into frankenstein Resolved conflicts against the already-merged origin/main: - mosaic-tileset-2d.ts: kept the antimeridian-crossing-fixes world-copy gate fix (subViewports != null, robust stale-index guard), preserved frankenstein's GeoBoundingBox-returning getTileMetadata, and dropped the now-redundant maxRequests/sortItemsByDistanceFromViewportCenter block (removed upstream in developmentseed#669 now that deck.gl 9.4 handles center-first loading natively). - render-gray.ts / data.ts / README: kept the more current, non-contradictory versions (createTextureProps shared helper; MosaicLayer's own normalizeSourceBbox handles antimeridian unwrapping internally, so the example no longer needs to do it manually). - Updated mosaic-tileset-2d.test.ts's "does not run world-copy passes" case for subViewports.length === 1 to match the corrected gate semantics (it now correctly finds a source needing a shifted world-copy pass even when only one subViewport is visible). - pnpm-lock.yaml regenerated via pnpm install. Full monorepo build + test suite green (deck.gl-raster 155/155, deck.gl-geotiff 43/43, and all other packages) after `git submodule update --init --recursive` to pull in previously-uninitialized geozarr submodules.
kylebarron
added a commit
to willjnz/deck.gl-raster
that referenced
this pull request
Oct 21, 2026
…idian Resolve conflicts in MosaicTileset2D: keep the world-copy search passes and apply main's `extent` filter (developmentseed#688) to their combined matches. Main removed the center-out sort (developmentseed#669), so the merge drops it too. Co-Authored-By: Claude Opus 5.5 <[email protected]>
5 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
deck.gl's TileLayer now has native center-first tile loading support, so we no longer need our workarounds
Note
This PR description was written by Claude (Claude Code), not by @kylebarron.
Since deck.gl 9.4,
Tileset2Dranks tile requests by screen distance from the viewport center and re-ranks them as the view moves. That makes our own center-out sorts from #477 redundant, so this removes them.RasterTileset2D(COGLayer, MultiCOGLayer, ZarrLayer):getTileIndicesreturns the traversal result without sorting.MosaicTileset2D(MosaicLayer):getTileMetadatanow returns the tile bbox as{west, south, east, north}instead of an array. deck.gl only reads that shape, so before this change every mosaic tile got the same fallback priority. Its sort is removed too.undefinedand dropped every mosaic tile. The object bbox fixes that as a side effect.sort-by-distance.ts, its tests, and the internal_sortItemsByDistanceFromViewportCenterexport.Not a breaking change:
MosaicTileset2Disn't exported, theMosaicLayercallbacks still receive the source with itsbboxarray, andMosaicSource.bboxis unchanged.Testing
{west, south, east, north}bbox. It failed before the change.🤖 Written by Claude Code on behalf of @kylebarron.