@bendyline/molen-tooling 0.0.1 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +22 -4
- package/dist/capture/harness.js +216 -216
- package/dist/capture/worldgen-preview.js +288 -288
- package/dist/cli.mjs +134 -12
- package/dist/docs-src/guide/3d-art-guidelines.md +2 -2
- package/dist/docs-src/guide/3d-model-assets.md +49 -13
- package/dist/docs-src/guide/adaptive-performance.md +4 -0
- package/dist/docs-src/guide/agent-loop.md +6 -6
- package/dist/docs-src/guide/aircraft.md +25 -17
- package/dist/docs-src/guide/audio.md +247 -0
- package/dist/docs-src/guide/browser-mount.md +17 -1
- package/dist/docs-src/guide/building-interiors.md +7 -5
- package/dist/docs-src/guide/determinism.md +27 -22
- package/dist/docs-src/guide/earth-view.md +444 -0
- package/dist/docs-src/guide/entities.md +17 -6
- package/dist/docs-src/guide/examples.md +39 -23
- package/dist/docs-src/guide/experience-playback.md +2 -3
- package/dist/docs-src/guide/game-samples.md +50 -21
- package/dist/docs-src/guide/graphics-performance.md +40 -8
- package/dist/docs-src/guide/input.md +9 -0
- package/dist/docs-src/guide/markers.md +52 -0
- package/dist/docs-src/guide/materials.md +10 -3
- package/dist/docs-src/guide/navigation.md +144 -0
- package/dist/docs-src/guide/project.md +23 -3
- package/dist/docs-src/guide/quickstart.md +39 -30
- package/dist/docs-src/guide/recognizable-places.md +24 -17
- package/dist/docs-src/guide/rendering-backends.md +5 -4
- package/dist/docs-src/guide/scripting.md +8 -4
- package/dist/docs-src/guide/sky.md +26 -9
- package/dist/docs-src/guide/source-bundles.md +0 -1
- package/dist/docs-src/guide/structure-library.md +20 -10
- package/dist/docs-src/guide/terrain.md +51 -6
- package/dist/docs-src/guide/vehicles.md +27 -14
- package/dist/docs-src/guide/worldgen.md +34 -24
- package/dist/docs-src/llms.txt +35 -18
- package/dist/docs-src/schemas/README.md +4 -1
- package/dist/docs-src/schemas/archive-set.md +175 -0
- package/dist/docs-src/schemas/components.md +1104 -1
- package/dist/docs-src/schemas/matgraph.md +6 -0
- package/dist/docs-src/schemas/soundbank.md +251 -0
- package/dist/docs-src/schemas/structure-placements.md +496 -0
- package/dist/docs-src/schemas/terrain-package.md +120 -0
- package/dist/index.d.mts +31 -3
- package/dist/index.mjs +2 -2
- package/dist/{mcp-BFnCWrg0.mjs → mcp-BTVwVKFb.mjs} +78 -4
- package/dist/{ops-BGxhSP6w.mjs → ops-BPdHodFR.mjs} +1181 -61
- package/dist/templates/city-courier/README.md +66 -0
- package/dist/templates/city-courier/checks.json +20 -0
- package/dist/templates/city-courier/commands.json +32 -0
- package/dist/templates/city-courier/delivery-run.replay.json +214 -0
- package/dist/templates/city-courier/gen/molen-types.ts +1016 -0
- package/dist/templates/city-courier/index.html +2 -0
- package/dist/templates/city-courier/package.json +26 -0
- package/dist/templates/city-courier/project.json +8 -0
- package/dist/templates/city-courier/scene.json +3474 -0
- package/dist/templates/city-courier/scripts/game.ts +131 -0
- package/dist/templates/city-courier/scripts/molen-scripts.d.ts +1288 -0
- package/dist/templates/city-courier/scripts/tsconfig.json +16 -0
- package/dist/templates/city-courier/src/audio.ts +96 -0
- package/dist/templates/city-courier/src/game-shell.css +317 -0
- package/dist/templates/city-courier/src/main.ts +84 -0
- package/dist/templates/city-courier/src/scene.ts +17 -0
- package/dist/templates/city-courier/src/vite-env.d.ts +1 -0
- package/dist/templates/city-courier/src/worker.ts +5 -0
- package/dist/templates/city-courier/test/headless.test.ts +95 -0
- package/dist/templates/city-courier/test/playthrough.test.js +52 -0
- package/dist/templates/city-courier/test/replay.test.ts +22 -0
- package/dist/templates/city-courier/tsconfig.json +17 -0
- package/dist/templates/city-courier/vite.config.ts +19 -0
- package/dist/templates/cubes/README.md +51 -0
- package/dist/templates/cubes/index.html +16 -0
- package/dist/templates/cubes/package.json +24 -0
- package/dist/templates/cubes/scene.json +15 -0
- package/dist/templates/cubes/src/cubes.ts +100 -0
- package/dist/templates/cubes/src/main.ts +21 -0
- package/dist/templates/cubes/src/worker.ts +15 -0
- package/dist/templates/cubes/test/headless.test.ts +98 -0
- package/dist/templates/cubes/tsconfig.json +17 -0
- package/dist/templates/cubes/vite.config.ts +17 -0
- package/dist/templates/data-viz/README.md +47 -0
- package/dist/templates/data-viz/camera-track.json +12 -0
- package/dist/templates/data-viz/data.json +9 -0
- package/dist/templates/data-viz/index.html +16 -0
- package/dist/templates/data-viz/package.json +25 -0
- package/dist/templates/data-viz/scene.json +7 -0
- package/dist/templates/data-viz/src/main.ts +39 -0
- package/dist/templates/data-viz/src/viz.ts +91 -0
- package/dist/templates/data-viz/src/worker.ts +12 -0
- package/dist/templates/data-viz/test/headless.test.ts +75 -0
- package/dist/templates/data-viz/tsconfig.json +17 -0
- package/dist/templates/data-viz/vite.config.ts +16 -0
- package/dist/templates/figures-gallery/README.md +46 -0
- package/dist/templates/figures-gallery/index.html +16 -0
- package/dist/templates/figures-gallery/package.json +25 -0
- package/dist/templates/figures-gallery/scene.json +276 -0
- package/dist/templates/figures-gallery/src/main.ts +44 -0
- package/dist/templates/figures-gallery/src/worker.ts +17 -0
- package/dist/templates/figures-gallery/test/headless.test.ts +90 -0
- package/dist/templates/figures-gallery/tsconfig.json +17 -0
- package/dist/templates/figures-gallery/vite.config.ts +17 -0
- package/dist/templates/index.json +191 -0
- package/dist/templates/skybound/README.md +66 -0
- package/dist/templates/skybound/checks.json +24 -0
- package/dist/templates/skybound/commands.json +32 -0
- package/dist/templates/skybound/first-leap.replay.json +224 -0
- package/dist/templates/skybound/gen/molen-types.ts +1016 -0
- package/dist/templates/skybound/index.html +2 -0
- package/dist/templates/skybound/package.json +26 -0
- package/dist/templates/skybound/project.json +8 -0
- package/dist/templates/skybound/scene.json +1777 -0
- package/dist/templates/skybound/scripts/game.ts +122 -0
- package/dist/templates/skybound/scripts/molen-scripts.d.ts +1288 -0
- package/dist/templates/skybound/scripts/tsconfig.json +16 -0
- package/dist/templates/skybound/src/audio.ts +96 -0
- package/dist/templates/skybound/src/game-shell.css +317 -0
- package/dist/templates/skybound/src/main.ts +63 -0
- package/dist/templates/skybound/src/scene.ts +17 -0
- package/dist/templates/skybound/src/vite-env.d.ts +1 -0
- package/dist/templates/skybound/src/worker.ts +5 -0
- package/dist/templates/skybound/test/headless.test.ts +124 -0
- package/dist/templates/skybound/test/playthrough.test.js +38 -0
- package/dist/templates/skybound/test/replay.test.ts +22 -0
- package/dist/templates/skybound/tsconfig.json +17 -0
- package/dist/templates/skybound/vite.config.ts +19 -0
- package/dist/templates/terrain-flyover/README.md +46 -0
- package/dist/templates/terrain-flyover/index.html +16 -0
- package/dist/templates/terrain-flyover/package.json +26 -0
- package/dist/templates/terrain-flyover/src/flyover.ts +23 -0
- package/dist/templates/terrain-flyover/src/main.ts +93 -0
- package/dist/templates/terrain-flyover/terrain.json +15 -0
- package/dist/templates/terrain-flyover/test/headless.test.ts +72 -0
- package/dist/templates/terrain-flyover/tsconfig.json +17 -0
- package/dist/templates/terrain-flyover/vite.config.ts +15 -0
- package/dist/templates/top-down-arena/README.md +65 -0
- package/dist/templates/top-down-arena/arena-skirmish.replay.json +204 -0
- package/dist/templates/top-down-arena/index.html +16 -0
- package/dist/templates/top-down-arena/package.json +26 -0
- package/dist/templates/top-down-arena/project.json +10 -0
- package/dist/templates/top-down-arena/scene.json +182 -0
- package/dist/templates/top-down-arena/scripts/chase.ts +17 -0
- package/dist/templates/top-down-arena/scripts/combat.ts +13 -0
- package/dist/templates/top-down-arena/scripts/control.ts +8 -0
- package/dist/templates/top-down-arena/scripts/molen-scripts.d.ts +1258 -0
- package/dist/templates/top-down-arena/scripts/spawner.ts +11 -0
- package/dist/templates/top-down-arena/scripts/tsconfig.json +16 -0
- package/dist/templates/top-down-arena/src/arena.ts +8 -0
- package/dist/templates/top-down-arena/src/audio.ts +96 -0
- package/dist/templates/top-down-arena/src/gen/molen-types.ts +1020 -0
- package/dist/templates/top-down-arena/src/main.ts +34 -0
- package/dist/templates/top-down-arena/src/scene.ts +24 -0
- package/dist/templates/top-down-arena/src/vite-env.d.ts +1 -0
- package/dist/templates/top-down-arena/src/worker.ts +7 -0
- package/dist/templates/top-down-arena/test/headless.test.ts +87 -0
- package/dist/templates/top-down-arena/test/replay.test.ts +22 -0
- package/dist/templates/top-down-arena/tsconfig.json +17 -0
- package/dist/templates/top-down-arena/types/arena.types.json +54 -0
- package/dist/templates/top-down-arena/vite.config.ts +21 -0
- package/package.json +14 -14
package/dist/docs-src/llms.txt
CHANGED
|
@@ -4,10 +4,20 @@
|
|
|
4
4
|
> three.js rendering client, authored through JSON schemas, a small typed API, and a headless
|
|
5
5
|
> dev loop. This bundle is version-locked to the engine release.
|
|
6
6
|
|
|
7
|
-
Engine version: 0.0.
|
|
7
|
+
Engine version: 0.0.3. three.js peer range: >=0.184.0 <0.187.0 (developed against 0.184.0). Node ≥ 22.13, ESM only.
|
|
8
8
|
|
|
9
9
|
## Start here
|
|
10
10
|
|
|
11
|
+
This bundle ships inside `@bendyline/molen-tooling` at `dist/docs-src/` (in a project:
|
|
12
|
+
`node_modules/@bendyline/molen-tooling/dist/docs-src/llms.txt`) and is published at
|
|
13
|
+
https://molen.dev/llms.txt. Everything it describes works from the npm packages; no clone of the
|
|
14
|
+
engine repository is needed. `npx @bendyline/molen-tooling new <name>` scaffolds a project, and
|
|
15
|
+
`--template <sample>` copies one of the samples instead (`molen templates` lists them). Every
|
|
16
|
+
sample plays at https://molen.dev/play/. Content packs (entity models, the default style pack,
|
|
17
|
+
Earth catalogs, stars) are never in npm packages: `npx molen pack fetch https://molen.dev/packs/index.json`
|
|
18
|
+
downloads them into a project and pins them in project.json.
|
|
19
|
+
|
|
20
|
+
- [Quickstart](guide/quickstart.md): npm-first — scaffold, run the headless loop, open the browser; start from a sample template.
|
|
11
21
|
- [Agent loop](guide/agent-loop.md): the author → validate → simulate → assert → screenshot loop, with copy-paste commands.
|
|
12
22
|
- [Browser experience playback](guide/experience-playback.md): host any built sample, drive real keyboard/pointer navigation, and capture screenshots plus diagnostics.
|
|
13
23
|
- [Projects & types](guide/project.md): project.json, the namespaced entity type registry, reservations, and typed TS authoring (`defineExperience` + `molen types gen`).
|
|
@@ -17,11 +27,14 @@ Engine version: 0.0.1. three.js peer range: >=0.184.0 <0.187.0 (developed agains
|
|
|
17
27
|
- [Determinism](guide/determinism.md): the contract — what reproduces and at what level per subsystem, what breaks it, what `STATE_FORMAT` means for save files and recorded replays, and what is explicitly not promised.
|
|
18
28
|
- [Browser mount](guide/browser-mount.md): `buildWorld` in a Worker + `await mountExperience` on the page; events and state for HUDs.
|
|
19
29
|
- [Input profiles and joysticks](guide/input.md): keyboard/controller remapping, raw axes, walking/driving/flying profiles, analog commands, and optional React controls.
|
|
30
|
+
- [Camera navigation](guide/navigation.md): orbit, fly, walk (capsule collision against streamed geometry) and follow cameras for `createViewer` hosts; one input model across keys, gamepad, pointer gestures and an on-screen touch stick.
|
|
31
|
+
- [World markers](guide/markers.md): screen-sized photo pins and labels pinned to world positions, ground-snapped, occluded, faded, budgeted and pickable.
|
|
32
|
+
- [Earth view](guide/earth-view.md): `mountEarthView` from `@bendyline/molen-earth` — real-world terrain, buildings, orbit/walk/drive, drivable cars, lat/lon markers, credits and adaptive quality in one call.
|
|
20
33
|
- [WebGPU and WebGL](guide/rendering-backends.md): the `backend` option ('auto' | 'webgl' | 'webgpu') on the asynchronous client factories, legacy WebGL fallback, compatible materials, and world-explorer comparisons.
|
|
21
34
|
- [Earth and authored skies](guide/sky.md): day/night cycles, geographic Sun/Moon positions and lunar phases, catalog stars, simulation clocks, custom-world palettes, and the sky observatory.
|
|
22
35
|
- [Weather and physical atmosphere](guide/weather.md): independent clouds, precipitation and visibility; profiles, temperature/pressure/wind for simulation and aircraft physics; cloud/rain/snow rendering.
|
|
36
|
+
- [Sound and music](guide/audio.md): sound banks, `audioEnvironment`/`audioSource`/`audioZone` rules driven by weather, sky, listener and entity signals, `molen.audio.*` in scripts, `molen audio plan` to hear a scene headlessly, and the CC0 `molen.sounds` pack.
|
|
23
37
|
- [Graphics performance](guide/graphics-performance.md): sparse transforms, static instancing, worker preparation, staged uploads, animation/light policy and terrain transitions.
|
|
24
|
-
- [Quickstart](guide/quickstart.md): zero-to-cubes in Node and the browser.
|
|
25
38
|
- [Terrain and world explorer](guide/terrain.md): fixed-grid and screen-space pyramid streaming,
|
|
26
39
|
projected Earth coordinates, optional semantic tile layers, the installable tiled-world package
|
|
27
40
|
contract, and sample app.
|
|
@@ -29,7 +42,7 @@ Engine version: 0.0.1. three.js peer range: >=0.184.0 <0.187.0 (developed agains
|
|
|
29
42
|
- [Worldgen: styled buildings and scatter](guide/worldgen.md): any outline → a styled building; `worldgenBuilding` component, `molen.worldgen.*` script queries, worker + cache for map tiles
|
|
30
43
|
(footprint analysis, roofs, walls), labeled polygons → deterministic props, style packs, and the
|
|
31
44
|
Earth binding (region atlas, terrain-semantics adapter, tile renderers).
|
|
32
|
-
- [Default structure library](guide/structure-library.md): 120 resizable buildings in 13 taxonomies,
|
|
45
|
+
- [Default structure library](guide/structure-library.md): 120 resizable buildings in 13 taxonomies, 51 shared construction materials, regional placement and the interactive model sheet.
|
|
33
46
|
- [Recognizable places](guide/recognizable-places.md): store identity matching, reusable signs, tenant facades and mapped outdoor props.
|
|
34
47
|
- [Building interiors](guide/building-interiors.md): deterministic layouts by use, real entrances and frontage windows, lazy rendering and walk collision.
|
|
35
48
|
- [3D art guidelines](guide/3d-art-guidelines.md): shared polygonal fidelity, scale, material library, LOD and visual review for static and procedural models.
|
|
@@ -42,7 +55,7 @@ Engine version: 0.0.1. three.js peer range: >=0.184.0 <0.187.0 (developed agains
|
|
|
42
55
|
- [Vehicle interiors and model signals](guide/vehicle-interiors.md): model-owned cabins, declarative simulation-to-GLB bindings, script-owned telemetry, and nearby detail loading.
|
|
43
56
|
- [Figures](guide/figures.md): stylized humans, bipeds and quadrupeds: presets and descriptors, canonical rigs and sockets, deterministic gaits, `figureAttachment` accessories, riders, and `molen figure preview`.
|
|
44
57
|
- [Complete game samples](guide/game-samples.md): city driving, first-person dungeon, and platformer; shared follow cameras and XY platform physics.
|
|
45
|
-
- [
|
|
58
|
+
- [Samples gallery](guide/examples.md): every sample with its molen.dev/play link and `--template` id, plus the capability layers (kinematics,
|
|
46
59
|
character, pathfinding, physics-rapier, terrain) — copy-and-modify starting points.
|
|
47
60
|
|
|
48
61
|
> **Script trust:** a scene manifest's `scripts` are evaluated **in-process** — by the `molen`
|
|
@@ -55,10 +68,12 @@ Engine version: 0.0.1. three.js peer range: >=0.184.0 <0.187.0 (developed agains
|
|
|
55
68
|
> [guide/scripting.md](guide/scripting.md) "Script trust". Path arguments to the CLI and MCP tools
|
|
56
69
|
> are likewise trusted user intent: they are read, written or imported as given, wherever they point.
|
|
57
70
|
|
|
58
|
-
> **Truth rule for agents:**
|
|
59
|
-
> The `docs/` folder is the original *design plan*: historical,
|
|
60
|
-
> code — treat it as intent, not fact. `molen docs search`
|
|
61
|
-
>
|
|
71
|
+
> **Truth rule for agents:** this bundle and the published packages (their `.d.mts` types) are the
|
|
72
|
+
> shipped engine. The engine repository's `docs/` folder is the original *design plan*: historical,
|
|
73
|
+
> not maintained, and it may lag the code — treat it as intent, not fact. `molen docs search`
|
|
74
|
+
> searches this bundle (inside the engine repository, `--design` adds `docs/`, tagged). Agents
|
|
75
|
+
> working *on* the engine start at the repository's [AGENTS.md](https://github.com/bendyline/molen/blob/main/AGENTS.md). Scaffold
|
|
76
|
+
> a starter with `molen new`.
|
|
62
77
|
|
|
63
78
|
## Schema reference (autogenerated)
|
|
64
79
|
|
|
@@ -76,6 +91,7 @@ Schema + example, generated from the registry) live in [schemas/](schemas/README
|
|
|
76
91
|
- [Command envelope](schemas/command.md) · [Assertions](schemas/assert.md)
|
|
77
92
|
- [Keyframe](schemas/keyframe.md) · [Delta](schemas/delta.md) · [Replay](schemas/replay.md)
|
|
78
93
|
- [Components](schemas/components.md) — every component with units and axis conventions
|
|
94
|
+
- [Sound bank](schemas/soundbank.md) (`molen/soundbank@1`: sound ids → clips, loops, gain, pitch, bus, provenance)
|
|
79
95
|
|
|
80
96
|
## The API surface
|
|
81
97
|
|
|
@@ -83,15 +99,16 @@ Schema + example, generated from the registry) live in [schemas/](schemas/README
|
|
|
83
99
|
- Component vocabulary: [schemas/components.md](schemas/components.md) or `molen components`.
|
|
84
100
|
- three.js surface + escape hatch (peer range 0.184–0.186): [guide/three-surface.md](guide/three-surface.md).
|
|
85
101
|
- Writing a capability package: [guide/capability-authoring.md](guide/capability-authoring.md).
|
|
86
|
-
- Kernel & ECS design notes: [02-packages-and-apis.md §3](
|
|
102
|
+
- Kernel & ECS design notes: [02-packages-and-apis.md §3](https://github.com/bendyline/molen/blob/main/docs/02-packages-and-apis.md) (design plan).
|
|
87
103
|
|
|
88
|
-
## Tooling — CLI (`npx molen <cmd>` in a project that installs `@bendyline/molen-tooling
|
|
104
|
+
## Tooling — CLI (`npx molen <cmd>` in a project that installs `@bendyline/molen-tooling`)
|
|
89
105
|
|
|
90
|
-
- `molen new <name
|
|
106
|
+
- `molen new <name> [--template <id>]` — scaffold a runnable project (project.json + scene + type registry + setup + checks), or copy a sample · `molen templates` — list the sample templates
|
|
91
107
|
- `molen validate <file> [--kind k] [--project p]` — validate an asset (pinpoint, fixable errors; scene `type` refs resolve through the project)
|
|
92
108
|
- `molen sim run <scene|name> --ticks N [--setup m] [--commands f] [--assert f] [--hash]`
|
|
93
109
|
- `molen asset import <file.glb> [--id <id>] [--trimesh]` · `asset inspect <ref> [--verify]` · `asset list` · `asset shot <ref> --out-dir d [--variant ktx2]`
|
|
94
|
-
- `molen pack build <dir> --out-dir d` · `pack inspect|verify <pack>` · `pack extract <pack> --out-dir d` · `pack fetch <url> [--project p]` — content packs (deterministic zips with a manifest); CLI ops find them via project.json `packs` and `MOLEN_PACKS`
|
|
110
|
+
- `molen pack build <dir> --out-dir d` · `pack inspect|verify <pack>` · `pack extract <pack> --out-dir d` · `pack fetch <url> [ids…] [--out-dir d] [--project p]` — content packs (deterministic zips with a manifest); CLI ops find them via project.json `packs` and `MOLEN_PACKS`
|
|
111
|
+
- `molen audio plan <scene> --ticks N [--bank b.json] [--commands f] [--weather w] [--mode m]` — list the loops and one-shots a scene would play, headlessly · `audio import <file> --id <id> --bank <bank.json> --license <spdx>` · `audio check <bank.json>`
|
|
95
112
|
- `molen asset pack <ref>|--all` — runtime GLB variant (KTX2 textures + mips, 4-8x less GPU memory) · `asset stage --out-dir d [--variant ktx2]` — browser bundle + assets.index.json
|
|
96
113
|
- `molen drive <scene> --actions f --out-dir d [--assert f]` — PLAY a scene: commands in, frames out (deterministic)
|
|
97
114
|
- `molen play <built-app-dir> --scenario f --out-dir d` — PLAY a browser experience: UI inputs in, screenshots/probes/diagnostics out
|
|
@@ -113,17 +130,17 @@ Schema + example, generated from the registry) live in [schemas/](schemas/README
|
|
|
113
130
|
|
|
114
131
|
`validate_asset`, `run_simulation`, `screenshot_scene`, `export_frames`, `rasterize_material`,
|
|
115
132
|
`run_replay`, `diff_snapshots`, `apply_uv_paint`, `list_schemas`, `get_schema`, `list_components`,
|
|
116
|
-
`get_component`, `search_docs`, `describe_op`, `new_experience`, `get_project`, `list_types`,
|
|
133
|
+
`get_component`, `search_docs`, `describe_op`, `new_experience`, `list_templates`, `get_project`, `list_types`,
|
|
117
134
|
`check_types`, `reserve_type`, `generate_types`, `import_asset`, `inspect_asset`, `pack_asset`, `stage_assets`,
|
|
118
135
|
`list_assets`, `drive_scene` (returns frames as IMAGES), `play_experience` (plays a built browser app and returns frames as IMAGES), `screenshot_asset` (turntable images),
|
|
119
136
|
`test_types`, `worldgen_preview` (generated buildings as IMAGES), `worldgen_bake`, `worldgen_stats`,
|
|
120
|
-
`figure_preview` (figures as IMAGES), `list_figure_presets`. Call `describe_op` for I/O contracts.
|
|
137
|
+
`figure_preview` (figures as IMAGES), `list_figure_presets`, `plan_audio`, `import_sound`, `check_soundbank`. Call `describe_op` for I/O contracts.
|
|
121
138
|
|
|
122
139
|
|
|
123
|
-
## Design reference (for deeper questions)
|
|
140
|
+
## Design reference (for deeper questions; the historical design plan, on GitHub)
|
|
124
141
|
|
|
125
|
-
- [Kernel design](
|
|
126
|
-
- [Materials & assets](
|
|
127
|
-
- [Phase plan](
|
|
142
|
+
- [Kernel design](https://github.com/bendyline/molen/blob/main/docs/04-kernel-design.md) · [Client design](https://github.com/bendyline/molen/blob/main/docs/05-client-design.md)
|
|
143
|
+
- [Materials & assets](https://github.com/bendyline/molen/blob/main/docs/06-materials-and-assets.md) · [Tooling & testing](https://github.com/bendyline/molen/blob/main/docs/07-tooling-and-testing.md)
|
|
144
|
+
- [Phase plan](https://github.com/bendyline/molen/blob/main/docs/08-phase-plan.md) · [Questions & risks](https://github.com/bendyline/molen/blob/main/docs/09-questions-and-risks.md)
|
|
128
145
|
|
|
129
146
|
- [Adaptive rendering performance](guide/adaptive-performance.md) — device feedback, frame/GPU timing, live terrain budgets, screen-space object LOD and worker boundaries.
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
# Schema reference
|
|
2
2
|
|
|
3
|
-
Autogenerated from the
|
|
3
|
+
Autogenerated from the schema registry `molen validate` checks against; `molen schema list` and `molen schema get <kind>` print the same set at runtime.
|
|
4
4
|
|
|
5
5
|
- [Components](components.md) — the component vocabulary (`molen components`)
|
|
6
|
+
- [Archive set](archive-set.md) — `molen/archive-set@1`
|
|
6
7
|
- [Architectural style](archstyle.md) — `molen/archstyle@1`
|
|
7
8
|
- [Assertion document](assert.md) — `molen/assert@1`
|
|
8
9
|
- [Asset sidecar](asset.md) — `molen/asset@1`
|
|
@@ -27,7 +28,9 @@ Autogenerated from the registered schemas (`pnpm docs:gen`; CI runs `pnpm docs:c
|
|
|
27
28
|
- [Replay fixture](replay.md) — `molen/replay@1`
|
|
28
29
|
- [Scatter rules](scatter.md) — `molen/scatter@1`
|
|
29
30
|
- [Scene manifest](scene.md) — `molen/scene@3`
|
|
31
|
+
- [Sound bank](soundbank.md) — `molen/soundbank@1`
|
|
30
32
|
- [Logical source bundle](source-bundle.md) — `molen/source-bundle@1`
|
|
33
|
+
- [Geographic structure placements](structure-placements.md) — `molen/structure-placements@1`
|
|
31
34
|
- [Style pack manifest](stylepack.md) — `molen/stylepack@1`
|
|
32
35
|
- [Terrain descriptor](terrain.md) — `molen/terrain@2`
|
|
33
36
|
- [Terrain package manifest](terrain-package.md) — `molen/terrain-package@1`
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# Archive set (`molen/archive-set@1`)
|
|
2
|
+
|
|
3
|
+
One tile pyramid split across PMTiles archives: a coarse base plus detail archives partitioned by the tile at a fixed level.
|
|
4
|
+
|
|
5
|
+
## Example
|
|
6
|
+
|
|
7
|
+
```json
|
|
8
|
+
{
|
|
9
|
+
"format": "molen/archive-set@1",
|
|
10
|
+
"name": "world-features",
|
|
11
|
+
"tileType": "mvt",
|
|
12
|
+
"partitionLevel": 7,
|
|
13
|
+
"base": {
|
|
14
|
+
"url": "base.pmtiles",
|
|
15
|
+
"minLevel": 0,
|
|
16
|
+
"maxLevel": 7
|
|
17
|
+
},
|
|
18
|
+
"archives": [
|
|
19
|
+
{
|
|
20
|
+
"id": "pacific-northwest-01",
|
|
21
|
+
"url": "2026-09/pacific-northwest-01.pmtiles",
|
|
22
|
+
"minLevel": 8,
|
|
23
|
+
"maxLevel": 13,
|
|
24
|
+
"partitions": "2600-2603,2728-2731"
|
|
25
|
+
}
|
|
26
|
+
]
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## JSON Schema
|
|
31
|
+
|
|
32
|
+
```json
|
|
33
|
+
{
|
|
34
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
35
|
+
"type": "object",
|
|
36
|
+
"properties": {
|
|
37
|
+
"format": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"const": "molen/archive-set@1",
|
|
40
|
+
"description": "Format envelope; always 'molen/archive-set@1'."
|
|
41
|
+
},
|
|
42
|
+
"name": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"minLength": 1,
|
|
45
|
+
"description": "Archive set name."
|
|
46
|
+
},
|
|
47
|
+
"tileType": {
|
|
48
|
+
"type": "string",
|
|
49
|
+
"enum": [
|
|
50
|
+
"png",
|
|
51
|
+
"mvt"
|
|
52
|
+
],
|
|
53
|
+
"description": "Payload type shared by every archive: 'png' (e.g. PNG16 elevation) or 'mvt'."
|
|
54
|
+
},
|
|
55
|
+
"partitionLevel": {
|
|
56
|
+
"type": "integer",
|
|
57
|
+
"minimum": 0,
|
|
58
|
+
"maximum": 10,
|
|
59
|
+
"description": "Level whose tiles partition the detail archives; a detail tile belongs to the archive listing its ancestor at this level."
|
|
60
|
+
},
|
|
61
|
+
"base": {
|
|
62
|
+
"type": "object",
|
|
63
|
+
"properties": {
|
|
64
|
+
"url": {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"minLength": 1,
|
|
67
|
+
"description": "Archive URL, relative to this document or absolute (http/https)."
|
|
68
|
+
},
|
|
69
|
+
"minLevel": {
|
|
70
|
+
"type": "integer",
|
|
71
|
+
"minimum": 0,
|
|
72
|
+
"maximum": 30,
|
|
73
|
+
"description": "Coarsest level the base archive serves."
|
|
74
|
+
},
|
|
75
|
+
"maxLevel": {
|
|
76
|
+
"type": "integer",
|
|
77
|
+
"minimum": 0,
|
|
78
|
+
"maximum": 30,
|
|
79
|
+
"description": "Finest level the base archive serves."
|
|
80
|
+
},
|
|
81
|
+
"bytes": {
|
|
82
|
+
"type": "integer",
|
|
83
|
+
"minimum": 0,
|
|
84
|
+
"maximum": 9007199254740991,
|
|
85
|
+
"description": "Archive size in bytes."
|
|
86
|
+
},
|
|
87
|
+
"sha256": {
|
|
88
|
+
"type": "string",
|
|
89
|
+
"pattern": "^[0-9a-f]{64}$",
|
|
90
|
+
"description": "Hex sha256 of the archive."
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
"required": [
|
|
94
|
+
"url",
|
|
95
|
+
"minLevel",
|
|
96
|
+
"maxLevel"
|
|
97
|
+
],
|
|
98
|
+
"additionalProperties": false,
|
|
99
|
+
"description": "Optional coarse archive serving every level up to its maxLevel."
|
|
100
|
+
},
|
|
101
|
+
"archives": {
|
|
102
|
+
"type": "array",
|
|
103
|
+
"items": {
|
|
104
|
+
"type": "object",
|
|
105
|
+
"properties": {
|
|
106
|
+
"id": {
|
|
107
|
+
"type": "string",
|
|
108
|
+
"minLength": 1,
|
|
109
|
+
"description": "Unique archive id, e.g. \"pacific-northwest-02\"."
|
|
110
|
+
},
|
|
111
|
+
"url": {
|
|
112
|
+
"type": "string",
|
|
113
|
+
"minLength": 1,
|
|
114
|
+
"description": "Archive URL, relative to this document or absolute (http/https)."
|
|
115
|
+
},
|
|
116
|
+
"minLevel": {
|
|
117
|
+
"type": "integer",
|
|
118
|
+
"minimum": 0,
|
|
119
|
+
"maximum": 30,
|
|
120
|
+
"description": "Coarsest level the archive serves (at least partitionLevel)."
|
|
121
|
+
},
|
|
122
|
+
"maxLevel": {
|
|
123
|
+
"type": "integer",
|
|
124
|
+
"minimum": 0,
|
|
125
|
+
"maximum": 30,
|
|
126
|
+
"description": "Finest level the archive serves."
|
|
127
|
+
},
|
|
128
|
+
"partitions": {
|
|
129
|
+
"type": "string",
|
|
130
|
+
"pattern": "^(\\d+(-\\d+)?(,\\d+(-\\d+)?)*)?$",
|
|
131
|
+
"description": "Run-length list of partition cells it owns, as indices y * 2^partitionLevel + x (e.g. \"40-44,60\")."
|
|
132
|
+
},
|
|
133
|
+
"bounds": {
|
|
134
|
+
"minItems": 4,
|
|
135
|
+
"maxItems": 4,
|
|
136
|
+
"type": "array",
|
|
137
|
+
"items": {
|
|
138
|
+
"type": "number"
|
|
139
|
+
},
|
|
140
|
+
"description": "Informational [west, south, east, north] in degrees."
|
|
141
|
+
},
|
|
142
|
+
"bytes": {
|
|
143
|
+
"type": "integer",
|
|
144
|
+
"minimum": 0,
|
|
145
|
+
"maximum": 9007199254740991,
|
|
146
|
+
"description": "Archive size in bytes."
|
|
147
|
+
},
|
|
148
|
+
"sha256": {
|
|
149
|
+
"type": "string",
|
|
150
|
+
"pattern": "^[0-9a-f]{64}$",
|
|
151
|
+
"description": "Hex sha256 of the archive."
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"required": [
|
|
155
|
+
"id",
|
|
156
|
+
"url",
|
|
157
|
+
"minLevel",
|
|
158
|
+
"maxLevel",
|
|
159
|
+
"partitions"
|
|
160
|
+
],
|
|
161
|
+
"additionalProperties": false
|
|
162
|
+
},
|
|
163
|
+
"description": "Detail archives, each owning a disjoint set of partition cells."
|
|
164
|
+
}
|
|
165
|
+
},
|
|
166
|
+
"required": [
|
|
167
|
+
"format",
|
|
168
|
+
"name",
|
|
169
|
+
"tileType",
|
|
170
|
+
"partitionLevel",
|
|
171
|
+
"archives"
|
|
172
|
+
],
|
|
173
|
+
"additionalProperties": false
|
|
174
|
+
}
|
|
175
|
+
```
|