This document defines how Libration chooses, validates, onboards, and maintains map assets.
Map assets are not decorative backgrounds. They are geospatial substrates that must align with projection-space scene content.
Projection defines spatial truth.
Map assets must conform to the projection contract. Overlays must not be warped to fit an incorrect map.
Current supported map asset contract:
- equirectangular / Plate Carree.
- full-world extent.
- north-up.
- 2:1 aspect ratio.
- no padding.
- no borders.
- continuous dateline seam.
- longitude range from -180 to 180.
- latitude range from -90 to 90.
Future projections may be added later, but current onboarding must remain equirectangular unless the projection system is intentionally expanded.
Authoritative base-map inventory lives in:
src/assets/maps/base-map-catalog.json
The catalog owns:
- family ids.
- labels.
- categories.
- runtime paths.
- preview paths.
- attribution (primary credit line;
maps:prep --attributionsets this on onboarding). - optional
licenseNote(short usage or license summary for the selector; manual catalog curation today—extendmaps:prepwhen a substrate PR needs it). - optional
sourceLinks(up to two http(s) provenance or policy links for the selector; manual catalog curation today). - variant mode.
- onboarded months.
- default presentation.
- capabilities (including optional overlay-readability hints such as
reliefShaded,boundaryDense,chromaticDense,bathymetryShaded,fineScaleTexture,labelDense,etchedReliefDense, andsunGlintDense, alongsideoverlayOptimizedanddarkFriendly, for upstream overlay lift scaling without raster sampling). - recommended roles.
- placeholder or transitional status where applicable.
TypeScript owns:
- validation.
- alias handling (for example legacy
equirect-world-topography-v1/equirect-world-topo-v1→ Blue Marble T; distinct catalog familyequirect-world-topography-ne-v1for the static Natural Earth–lineage topography raster—seedocs/maps/MAP_ASSET_SOURCES.md). - fallback semantics.
- month-aware resolution.
- presentation merging.
- resolver APIs.
Runtime does not scan public/maps.
Some rasters are composition inputs: they inform upstream planetary illumination and tone (for example emissive night-light radiance fields), not the geographic substrate selected as scene.baseMap.id.
Rules (aligned with base maps):
- persist durable semantic family ids only (no concrete month paths or ad hoc URLs in config).
- satisfy the same equirectangular world contract as base maps until projection support expands.
- resolve through a bundled catalog (
src/assets/composition/emissive-composition-catalog.jsonfor emissive inputs), not runtime directory scans. - non-emissive twilight and day/night sampling are upstream constants-only tuning in
illuminationShading.ts(cumulative narrow passes; seePLAN.md), not additional catalog rasters.
Emissive night-light families are not exposed as selectable base maps; they are sampled inside the planetary illumination pipeline and emitted through the same single illumination rasterPatch contract as solar and lunar composition. The first validated ship asset is NASA Black Marble 2016 (1° grayscale JPEG) at public/maps/composition/equirect-world-night-lights-viirs-v1.jpg, documented under docs/maps/MAP_ASSET_SOURCES.md.
Authoritative emissive composition inventory (family ids and resolver-owned src paths) lives in:
src/assets/composition/emissive-composition-catalog.json
TypeScript owns validation, id canonicalization, and resolveEmissiveCompositionAsset / resolveEmissiveCompositionAssetIdToCanonicalId. Runtime does not scan public/maps for composition inputs.
Weather and cloud (not base-map catalog): live or forecast weather/cloud participation is not onboarded through base-map-catalog.json. Boundaries, Phase 10 lifecycle prerequisites, and sequencing for future upstream or layer participation are shipped in docs/specs/scene/weather-cloud-composition-plan.md (PLAN.md Slice 2 queue D closed; no runtime in that slice). Static climatology rasters (if ever added) follow the base-map rules in this document.
Persist the selected family id:
scene.baseMap.idDo not persist concrete raster paths, including month-specific paths.
Per-family presentation overrides should be keyed by family id:
scene.baseMap.presentationByMapId[scene.baseMap.id]Current variant modes:
type BaseMapVariantMode = "static" | "monthOfYear"A static family resolves to one concrete raster.
A month-aware family stores one selected family id in config but resolves a concrete monthly raster from product time (UTC civil month). The Layers selector surfaces the active month read-only when that family is selected (BaseMapStyleControl; see MAP_ASSET_SOURCES.md Blue Marble notes)—month is not a separate persisted config field.
Rules:
- monthly rasters live under
public/maps/variants/<family-id>/. - monthly files use
01.jpgthrough12.jpg. base.jpgis the family fallback.- all monthly rasters must share projection, extent, dimensions, and alignment.
- missing month fallback walks backward by calendar month.
- backend image failure may exclude a concrete URL, but resolver owns fallback choice.
Use the map prep tool for curated source TIFF sets:
npm run maps:prep -- --variant-mode monthOfYear --family-id <family-id> --source-dir <source-dir> --label <label> --category <category> --attribution <attribution> --update-catalogReview the resulting git diff.
Do not hand-add files under public/maps without a catalog entry.
Prefer sources that are:
- public or permissibly redistributable.
- authoritative.
- well documented.
- projection-aware.
- high enough resolution for product use.
- stable enough to cite.
- compatible with AGPL distribution.
For each sourced family, retain:
- source name.
- source URL or dataset name.
- license or usage terms.
- processing workflow.
- projection/export settings.
- validation notes.
- known limitations.
Before accepting a map family:
- aspect ratio is exactly 2:1.
- full world extent is present.
- no border or padding.
- north is up.
- equator is centered.
- prime meridian is centered.
- poles map to top and bottom edges.
- known cities align.
- coastlines align against a trusted reference.
- all monthly variants share identical dimensions and alignment.
- preview exists.
- attribution exists.
- catalog metadata is correct.
Family ids should be durable semantic identifiers.
Change labels freely during curation. Rename ids only when intentionally breaking persisted references or when family lineage changes.
Recommended id pattern:
equirect-world-<family>-<variant>-v1
Examples:
equirect-world-legacy-v1
equirect-world-political-v1
equirect-world-topography-ne-v1
equirect-world-geology-v1
equirect-world-bathymetry-etopo-v1
equirect-world-landcover-modis-v1
equirect-world-climate-koppen-beck-v1
equirect-world-blue-marble-bm-v1
Candidate future families (beyond shipped static topography equirect-world-topography-ne-v1, political equirect-world-political-v1, geology equirect-world-geology-v1, bathymetry equirect-world-bathymetry-etopo-v1, land cover equirect-world-landcover-modis-v1, climate equirect-world-climate-koppen-beck-v1, population equirect-world-population-gpw-v1, Blue Marble month-aware families, and legacy reference equirect-world-legacy-v1 with bundled preview):
- additional climate normals products (preferred next queue A backlog: temperature / precipitation climatologies; shipped baseline: Köppen–Geiger present
equirect-world-climate-koppen-beck-v1; future: alternate Köppen epochs). - higher-resolution or alternate land-cover products (e.g. Copernicus 100m discrete map).
- alternate GPW population density epochs or display ramps for
equirect-world-population-gpw-v1when product-scoped. - night lights.
- high-contrast accessibility.
- paper/neutral styling.
- dark-friendly overlays.
- ocean current substrates.
Each should be treated as a curated geospatial product, not just an image.