Repository navigation
feat: Add Tianditu (TDT) label and terrain support - #225
Open
zishang520 wants to merge 1 commit into
Open
zishang520 wants to merge 1 commit into
zishang520 wants to merge 1 commit into
Conversation
zishang520
force-pushed
the
feat/tianditu-services
branch
2 times, most recently
from
October 8, 2026 09:05
541cc82 to
4009dce
Compare
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.
Add Tianditu DEM terrain and 3D place-name support to dc-sdk, while improving the existing Tianditu imagery services. The implementation follows the project's existing
TerrainFactory, layer lifecycle, and module export conventions.Main Changes
TerrainType.TDTandTerrainFactory.createTdtTerrain(), with support for Tianditu DEM requests, decompression, and elevation resampling.TdtLabelLayer, supporting POI text, icons, and optional road labels, with server-side styling, priority-based collision avoidance, show/hide controls, clear/refresh operations, and remove/re-add lifecycle support.candwprojections, and corrected the mapping between service levels and tile grids.ArrayBuffers. Beyond the service's maximum level, Cesium workers are reused to clip terrain meshes, reducing redundant computation on the main thread.src/workersentry points and copy the required resources, with improved async task handling, temporary-file cleanup, and development watch support.pakoandprotobufjsdependencies, expanded the API documentation and terrain examples, and updated the Tianditu examples to require users to provide their own Key.Validation
Usage Notes
resources/Workers/DC/decodeTdtTerrain.jsmust be deployed together with the SDK. When using a separate resource base URL, the worker path can be configured viaworkerUrl.