WikiMiniAtlas/Vector tiles

From OpenStreetMap Wiki
Jump to: navigation, search
Vector tiles with a custom debug style to highlight certain OSM attributes

The WikiMiniAtlas uses client-side rendered vector tiles for large zoom levels (13-30). Data is extracted from the OSM-Mapnik rendering database and cached in JSON format. ST_Intersection is used to remove data outside the tile areas (including a gutter area).

Buildings are only included in the JSON data at zoom level 14 and beyond. Building polygons are not cut using ST_Intersection. This allows progressive loading of building data. When zooming in the JSON data that is already present in the browser is used to render the new tiles. In parallel, requests for more detailed data are issued and the tiles are re-rendered as soon as the data is loaded. This allows immediate zooming without delays.

At zoom levels 15 and beyond, the building data is also used to overlay a 3D wireframe of the buildings if the OSM tags building:levels or height are present (min_height und building:min_levels are also used).

Rendering takes place on small, tile-sized canvas elements. The system degrades gracefully in Internet Explorer and browsers that are too old and crappy to support canvas elements (hey, I'm only one developer and the whole vector tile system was implemented in less than a week).

Planned features

  • time-dependent maps to visualize the start_date and end_date tags
  • custom styles to emphasize certain features (tunnels, railway lines etc.)