Bub's Maps

Method notes

Background for the rules in the README. File references are to the CoMaps revision pinned there.

One planet

Data versions

The engine keeps maps in a directory named after their data version, <v>/<region>.mwm.

Border crossings

verify_crossings.py compares the crossing lists of every pair of neighbouring regions (regions whose border polygons share at least three vertices). Some neighbours legitimately share no crossing way:

A “water border” rule would be wrong on both counts. Lakes carry ferries, and a river can be a land border without a bridge. So a pair with no recorded crossing passes only on evidence:

Generator crash fix

In the 2026-09-27 US build, one region (US_Missouri_Kansas) crashed the generator in the polygon tessellator (libtess2, WalkDirtyRegions → tessMeshAddEdgeVertex).

Pack grouping

The engine’s catalogue has about 1,150 regions (“leaves”). App packs bundle them:

Pack ids are stable and never encode the data version. Once a pack ships, its id is never removed or reused. plan_groups.py check --previous enforces that.

Point Roberts

Some US places can only be reached by road through another country: Point Roberts, Washington, is reachable only through British Columbia. The packs hold US maps only, so the unpatched router answers “no route” there, which reads as if no road existed.

The router change in patches/comaps-smoke-router-probe.patch checks, after a failed search, whether every road path between start and destination runs through maps that aren’t loaded. If so, it reports “needs more maps” (result code 9) and names them. It changes nothing in the packs. The offline smoke test routes Seattle → Point Roberts and back and expects code 9, so those two lines need the patch.

Elevation tile loading fix

The generator reads elevation tiles as <tile>.SRTMGL1.hgt.zip or as plain <tile>.hgt.

The pipeline still keeps one tile directory all-zip and covers every road cell, so the result doesn’t depend on the fix.

Elevation

From release 260929, every region carries an altitudes section: one height per road point, used for walking and cycling times and grades.

Sources:

Conversion (dem3dep.py): 3DEP tiles are GeoTIFFs whose pixel centres sit half an arc second off SRTM’s posts. Each SRTM post gets the bilinear value of the four nearest pixel centres, rounded to whole metres. 3DEP leaves the sea as “no data” where SRTM has 0 m, so the coast is first grown outwards by 30 rounds of neighbour means and the remaining open water is set to 0 m. The result is written in SRTM’s own tile format, so the generator reads it unchanged.

Checks:

Packaging

The app downloads packs as Apple-hosted Background Assets. Packaging never changes the data; it only arranges it.

Releases

Each release has a folder under releases/ with what is needed to rebuild it and to check a rebuild:

260929: OSM data as of 2026-09-29 20:22:51 UTC; World and 155 US regions in 46 packs; generator binary generator_tool SHA-256 233fbb77038ead75570fbc8553beed06dc8a237547089d0c4f9cfc3e44dd16ba.

Geofabrik may not keep dated extracts indefinitely. The same data can also be cut from the OpenStreetMap full-history planet at the replication timestamp.

Coverage notes