Skip to content

Adornments: short dataset name and an altitude bar - #167

Merged
xfischer merged 1 commit into
masterfrom
feat/adornments-elevation-bar
Nov 25, 2026
Merged

xfischer merged 1 commit into
masterfrom
feat/adornments-elevation-bar

Conversation

@xfischer

Copy link
Copy Markdown
Member

Summary

  • The adornment text shows only the dataset's short name (ShortName(): DEMDataSet.Name, Mapterhorn without its _zNN suffix). The long dataset and imagery attributions are dropped from the 3D text; they remain in the model credits. The text is capped at the size of the other labels (N, scale bar) so a short name isn't blown up.
  • New CreateElevationBar(bboxModelSpace, zBottom, zTop, minMeters, maxMeters): a white vertical bar just outside the north-east corner, from the lowest to the highest terrain point, with ticks and upright labels (797 m, 3220 m) facing south. Labels move apart when the bar is shorter than they are; a flat area gets a single label. Model space (Z up), final coordinates.
  • CreateModelAdornments keeps its signature (the imagery provider is now unused) so existing callers still build.

Used by the Elevation API (DEM.Net.WebAPI PR to follow).

Test plan

  • DEM.Net.WebAPI tests pass (129), including ShortName tests
  • Generated a Mapterhorn glTF of Verbier locally and rendered the Adornments mesh from above and from the south: name, arrow and scale bar in place, bar from 797 m to 3220 m, labels upright and readable
  • Look at a model in the site's 3D viewer

🤖 Generated with Claude Code

The adornment text is now the dataset's short name (Mapterhorn without its
zoom suffix) instead of the full dataset and imagery attributions, which stay
in the model credits. It is drawn at the size of the other labels.

New CreateElevationBar: a vertical bar at the model's north-east corner, from
its lowest to its highest point, with ticks and upright labels in meters
facing south. Labels move apart when the bar is shorter than they are.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@xfischer
xfischer merged commit 074acc2 into master Nov 25, 2026
3 checks passed
@xfischer
xfischer deleted the feat/adornments-elevation-bar branch November 25, 2026 08:58
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.

1 participant