v0.21.0 — Grid streets
Towns can now be planned, not just organic. A new layout knob lays a real geometric street grid aligned to the town's long axis, with matching rectangular blocks.
Added
SettlementConfig.layout—"organic"(default) or"grid". In grid mode a town gets:- a geometric street grid aligned to the footprint's principal (long) axis — two families of parallel thoroughfares clipped to the footprint, the central line of each marked
"main"; - gates where the main streets pierce the perimeter (plus a harbour gate when coastal);
- grid-aligned lots — blocks are bisected along the grid axes, so buildings come out rectangular and street-aligned;
- walls that splice the mid-edge grid gates into the wall ring as real gatehouse gaps.
- a geometric street grid aligned to the footprint's principal (long) axis — two families of parallel thoroughfares clipped to the footprint, the central line of each marked
- New preset
grid_cityand agrid-citygallery showcase. - New reusable geometry primitive
clip_line_to_convex(Liang–Barsky line ↔ convex-polygon clipping).
Compatibility
- The default (
layout="organic") output is byte-identical to v0.20.0 — all grid logic is gated behind the new mode. - Purely additive:
layoutserialises viato_dict/json_schema(new enum-field support inSettlementConfig). No public-API names added.
Full changelog: 7d18d4e...v0.21.0