Ten family trips as 3D maps, with water from OpenStreetMap: how they were made

Hello everyone,

Since 2016, Sandrine and I have been writing a family travel blog. For its tenth birthday, I wanted to rebuild ten of our trips as small explorable 3D maps, like scale models: Iceland, Martinique, the Isle of Skye, the Lofoten, the Dolomites, the Gulf of Morbihan… I’m sharing how they were made, because OpenStreetMap data plays a part in them and I’d value your feedback.

What the maps show

Each map is a block of real terrain where you can follow our route, with our photos placed along the way. The relief, the water and the routes are real. The rest of the scenery (trees, houses, boats) is illustrated, generated from satellite imagery.

The pipeline

  1. **Relief**: Mapbox Terrain-RGB elevation tiles, exported with heightmap.skydark.pl, a heightmap generator first made for Cities: Skylines. The settings of each export are stored with the data, so it can be redone. The areas range from 3 km (Chambord) to 650 km (the whole of Iceland).
  2. **Water**: the same tool reads the `water` and `waterway` layers of the Mapbox Streets vector tiles, built largely from OpenStreetMap data, and lowers those areas by 40 m. Python scripts detect these hollows to recover the outlines of coasts and lakes, down to rivers (trenches one or two pixels wide), then raise the water back to its level. At Chambord, the canal and the moats were traced from the Mapbox Streets map, which draws OSM’s polygons, and the château model is fitted to the moats.
  3. **Ground**: the colours come from Mapbox satellite imagery, sorted automatically into a few classes (forest, built-up, meadow, rock), leaving out clouds and haze.
  4. **Routes**: our GPX tracks.
  5. **Scenery**: generated in the browser from the forest and built-up densities. That gives up to 36,000 trees (pines near the sea, spruces below a tree line, palms in Martinique), houses, moored boats and gulls. A chamfer distance transform gives each cell its distance to the shore, which shapes the sea floor and the foam.
  6. **Rendering**: a small WebGL 2 renderer written for the project, with no 3D library. The data is compressed losslessly (predictive filters, then deflate): 7 MB for the ten maps.

What is measured, what is illustrated

  • The relief is real but exaggerated (up to ×2 depending on the map), to keep it readable.
  • The sea floor is drawn, not measured.
  • Trees and houses are placed by density, not one by one.

About the method

I’m an art director, not a developer: all the code (Python and JavaScript) was written in conversation with an AI (Claude), what people now call “vibe coding”. My job was to choose, compare and correct.

My questions

  • For now, the water reaches me through Mapbox Streets rather than from OSM directly. For a future map, would you start from an Overpass query or a Geofabrik extract for the water polygons and the coastline?
  • For buildings, I use a density read from the satellite imagery. OSM buildings would be more accurate: is extruding them in 3D over a few square kilometres reasonable, data-wise, for a web page?
  • More generally, if you see anything wrong in how the data is used or credited, I’d like to hear it.

The site, in English, with no sign-up and no ads: https://anniversary.troispasdecote.fr

Thanks in advance for your feedback,
Geoffrey

2 Likes

Cute! I would love to see this be made reusable - have you considered making this into an open-source project?

1 Like

Only Mapbox need an API with limits on the free plan, everything else is vibecoded by claude and myself looking for sources as photo and capture from google maps. I can think about it.

1 Like