Zig API
The engine is a Zig package named tile57 (v0.3.0, requires Zig 0.16).
Add it as a dependency and @import("tile57") for the curated public surface
(src/tile57.zig). The C ABI is a thin shim over this same API,
and both share the same shape: bake, then compose (or bake, then render) —
source charts bake once to per-chart archives, and every output is produced
from baked archives. These pages are grouped the same way as the C API.
note
Add it as a path dependency on a local clone (submodules initialised) —
zig fetch by URL/hash is currently broken because the package's declared
.paths omit vendor/ and include/. See
Installation.
Sections
| Page | What it covers |
|---|---|
| Errors & lifecycle | the error-union model, handle lifetime + threading, tile57.warmup, tile57.freeBytes, the version string |
| Bake | tile57.bake — charts → per-chart PMTiles archives |
| Render | the Chart — open modes, the render surfaces (pixel / surface callbacks / GPU scene / ASCII), the cursor pick, and metadata |
| Compose | tile57.compose — the ComposeSource stitching many charts into one |
| Portrayal assets | tile57.sprite — the sprite + area-fill pattern atlases |
| MapLibre style | tile57.style + tile57.Mariner — a concrete style JSON, colour tables, line styles |
| Low-level modules | Zig-only packages with no C ABI equivalent: tiling/encoding and the raw tile57.formats parsers |