Ratatoskr/scripts/ridge-bake/ridge-bake.schema.json
Meta Vens 65db62c986 ridge-bake: the ring is the bake, 32 azimuth tiles per card (schema 3)
The 72 degree window and the baked camera are deleted. The march's 6400 columns are the bake: seams run periodic round the ring (DP over three laps, middle kept), ridge.cards runs per tile on 204 columns with the matching normals, and the vertical anchors read the skyline of the whole ring. Each card tile carries its own distance_m; camera.r_max_m is the largest offset the per-card linear slide fits within 24 card px (and the resident gate allows). Tile, place and resident budgets replace the window's. Manifest schema 3, baker version 4. Tests and mutants rewritten for the ring.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-22 21:25:09 +01:00

322 lines
6.1 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "ridge-bake manifest v3 and index v1",
"$defs": {
"manifest": {
"type": "object",
"required": [
"schema",
"baker_version",
"bake_id",
"place",
"view",
"curvature",
"encoding",
"camera",
"cards",
"tiles",
"bytes",
"attribution"
],
"additionalProperties": false,
"properties": {
"schema": {
"const": 3
},
"baker_version": {
"type": "integer"
},
"bake_id": {
"type": "string"
},
"place": {
"type": "object",
"required": [
"id",
"name",
"lat",
"lon",
"altitude_km",
"eye_m",
"tz"
],
"additionalProperties": false,
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"lat": {
"type": "number"
},
"lon": {
"type": "number"
},
"altitude_km": {
"type": "number"
},
"eye_m": {
"type": "number"
},
"tz": {
"type": "string",
"format": "iana-tz"
}
}
},
"view": {
"type": "object",
"required": [
"look_az_deg",
"ring_w",
"tile_w",
"tiles",
"apron",
"plane_h",
"px_per_deg_h",
"px_per_deg_v",
"exaggeration",
"horizon_row",
"sky_row",
"near_row"
],
"additionalProperties": false,
"properties": {
"look_az_deg": {
"type": "number"
},
"ring_w": {
"const": 6400
},
"tile_w": {
"const": 200
},
"tiles": {
"const": 32
},
"apron": {
"const": 2
},
"plane_h": {
"type": "integer"
},
"px_per_deg_h": {
"type": "number"
},
"px_per_deg_v": {
"type": "number"
},
"exaggeration": {
"type": "number"
},
"horizon_row": {
"type": "number"
},
"sky_row": {
"type": "number"
},
"near_row": {
"type": "number"
}
}
},
"curvature": {
"type": "object",
"required": [
"r_earth_m",
"k_ref"
],
"additionalProperties": false,
"properties": {
"r_earth_m": {
"type": "number"
},
"k_ref": {
"type": "number"
}
}
},
"encoding": {
"type": "object",
"required": [
"log_d_min",
"log_d_max",
"normal"
],
"additionalProperties": false,
"properties": {
"log_d_min": {
"type": "number"
},
"log_d_max": {
"type": "number"
},
"normal": {
"const": "rt8"
}
}
},
"camera": {
"type": "object",
"required": [
"r_max_m"
],
"additionalProperties": false,
"properties": {
"r_max_m": {
"type": "number"
}
}
},
"cards": {
"type": "array",
"minItems": 1,
"maxItems": 6,
"items": {
"type": "object",
"required": [
"near_m",
"far_m"
],
"additionalProperties": false,
"properties": {
"near_m": {
"type": [
"number",
"null"
]
},
"far_m": {
"type": [
"number",
"null"
]
}
}
},
"description": "nearest first; the runtime paints the list last to first. near_m and far_m are the median seam depths over the ring, null at the ends."
},
"tiles": {
"type": "array",
"minItems": 32,
"maxItems": 32,
"items": {
"type": "array",
"minItems": 1,
"maxItems": 6,
"items": {
"type": [
"object",
"null"
],
"required": [
"top",
"h",
"distance_m",
"colour",
"geometry"
],
"additionalProperties": false,
"properties": {
"top": {
"type": "integer"
},
"h": {
"type": "integer"
},
"distance_m": {
"type": "number"
},
"colour": {
"type": "object",
"required": [
"file",
"bytes"
],
"additionalProperties": false,
"properties": {
"file": {
"type": "string"
},
"bytes": {
"type": "integer"
}
}
},
"geometry": {
"type": "object",
"required": [
"file",
"bytes"
],
"additionalProperties": false,
"properties": {
"file": {
"type": "string"
},
"bytes": {
"type": "integer"
}
}
}
}
}
},
"description": "tiles[t][i] is card i in tile t, or null where the card holds nothing in that tile (the client takes its distance from the neighbouring tiles). Tile t owns the ring columns [tile_w t, tile_w (t + 1)), column c at azimuth (c + 0.5) / ring_w x 360, 0 = north; its files hold [tile_w t - apron, tile_w (t + 1) + apron), wrapping at the ring's end, and are tile_w + 2 apron columns wide. top and h place the card's band back at its rows of the frame; distance_m = exp(median ln d) of the card's solid pixels in the tile that are not wall (the interior tile_w columns)."
},
"bytes": {
"type": "integer"
},
"attribution": {
"type": "object",
"required": [
"credit_line",
"licence",
"dem_source",
"url"
],
"additionalProperties": false,
"properties": {
"credit_line": {
"type": "string"
},
"licence": {
"type": "string"
},
"dem_source": {
"type": "string"
},
"url": {
"type": "string"
}
}
}
}
},
"index": {
"type": "object",
"required": [
"schema",
"default",
"places"
],
"additionalProperties": false,
"properties": {
"schema": {
"const": 1
},
"default": {
"type": "string"
},
"places": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
}