Water water
The format of the water packs, read from the published packs themselves. Machine-readable: water.json.
Format
Generated from:
water-naedition2026q4r1, schema_version 1; built by pyEfis tools/fetch_geofabrik_water.py at d87cd5c89736, packed by makerplane-data d1cf80098d0a · captured when it was published
pack_meta keys: attribution, cycle, id, kind, license, license_url, schema_version.
pack_meta
The pack's own header: the same id, kind, cycle and licence its manifest entry carries, so a pack copied away from the catalog still identifies itself.
| column | type | not null | default | primary key | description |
|---|---|---|---|---|---|
key | TEXT | 1 | A pack_meta field name (see the pack_meta table on the index page). | ||
value | TEXT | That field's value, as text. |
CREATE statement, verbatim
CREATE TABLE pack_meta (key TEXT PRIMARY KEY, value TEXT)
water_polygons
| column | type | not null | default | primary key | description |
|---|---|---|---|---|---|
id | INTEGER | 1 | |||
min_lat | REAL | yes | |||
max_lat | REAL | yes | |||
min_lon | REAL | yes | |||
max_lon | REAL | yes | |||
kind | TEXT | yes | |||
elev_ft | REAL | ||||
vertices | BLOB | yes | |||
triangles | BLOB | ||||
rings | BLOB |
CREATE statement, verbatim
CREATE TABLE water_polygons (
id INTEGER PRIMARY KEY AUTOINCREMENT,
min_lat REAL NOT NULL,
max_lat REAL NOT NULL,
min_lon REAL NOT NULL,
max_lon REAL NOT NULL,
kind TEXT NOT NULL,
elev_ft REAL,
vertices BLOB NOT NULL,
-- Pre-tessellated triangle indices into the ``vertices`` array,
-- packed little-endian (3 indices per triangle): uint16 for rows
-- of <= 65535 vertices, uint32 beyond (dense multi-ring cells;
-- the dtype is implied by the row's vertex count on both the
-- build and read side). NULL only when tessellation failed at
-- build time (logged as a warning). The GPU water renderer
-- uploads these directly to a GL element-array buffer with one
-- draw call per polygon.
triangles BLOB,
-- Ring topology for multi-ring (outer + hole) polygons, packed as
-- little-endian ring END offsets into ``vertices`` (earcut
-- convention: outer ring first, then each hole ring; same
-- uint16/uint32 vertex-count rule as ``triangles``). NULL for
-- plain single-ring polygons — the overwhelming majority. When
-- present, ``triangles`` was tessellated hole-aware, so island
-- holes are excluded from the fill (#44).
rings BLOB
)waterway_lines
| column | type | not null | default | primary key | description |
|---|---|---|---|---|---|
id | INTEGER | 1 | |||
fclass | TEXT | yes | |||
min_lat | REAL | ||||
max_lat | REAL | ||||
min_lon | REAL | ||||
max_lon | REAL | ||||
verts | BLOB | yes |
CREATE statement, verbatim
CREATE TABLE waterway_lines (
id INTEGER PRIMARY KEY,
fclass TEXT NOT NULL,
min_lat REAL, max_lat REAL, min_lon REAL, max_lon REAL,
verts BLOB NOT NULL
)Indexes
| index | table | columns | unique |
|---|---|---|---|
idx_bbox | water_polygons | min_lat, max_lat, min_lon, max_lon | |
idx_kind | water_polygons | kind |
R-trees
SQLite R*Tree virtual tables, the spatial index a reader queries by bounding box.
water_rtree: id, min_lat, max_lat, min_lon, max_lon
CREATE VIRTUAL TABLE water_rtree USING rtree(
id,
min_lat, max_lat,
min_lon, max_lon
)waterway_rtree: id, min_lat, max_lat, min_lon, max_lon
CREATE VIRTUAL TABLE waterway_rtree USING rtree(
id, min_lat, max_lat, min_lon, max_lon
)Not yet described
These have no inline comment in the builder's CREATE statement and no entry in docs/schema_descriptions.yaml. Their names and types above are still exact.
17: water_polygons.elev_ft, water_polygons.id, water_polygons.kind, water_polygons.max_lat, water_polygons.max_lon, water_polygons.min_lat, water_polygons.min_lon, water_polygons.rings, water_polygons.triangles, water_polygons.vertices, waterway_lines.fclass, waterway_lines.id, waterway_lines.max_lat, waterway_lines.max_lon, waterway_lines.min_lat, waterway_lines.min_lon, waterway_lines.verts