feat(simulation): load canonical 16-bit grayscale heightmap.png + downsample (D-202 #963)
Replace the atlas_body_heightmaps DB-BLOB loader with a per-body file loader (D-202 amendment): heightmap.rs reads the 16-bit grayscale heightmap.png (via the new png dep) from the body's terrain_reference path, normalizes to f32 [0,1], and rejects RGB so a reliefmap can't be misread as elevation. Adds BodyHeightmap::downsample (box-average, deterministic) so Layer 1 drops the high-res stored heightmap to the 512x256 working resolution. sea_level becomes body metadata carried alongside, not in the PNG. 4 loader tests pass. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -29,6 +29,7 @@ sysinfo = "0.35"
|
||||
serde_json = "1"
|
||||
rusqlite = { version = "0.32", features = ["bundled"] }
|
||||
bytemuck = "1"
|
||||
png = "0.17"
|
||||
toml = "0.8"
|
||||
aho-corasick = "1"
|
||||
# Economics simulation — Leontief + tâtonnement + D-180 event port (#821)
|
||||
|
||||
Reference in New Issue
Block a user