Mapnik Vector Tiles

Render maps with Mapnik that include OpenStreetMap data without running your own spatial database. Below are a set of experimental vector tile layers that you can use in Mapnik 2.1+ with the TileStache VecTiles Datasource. These tiles provide OpenStreetMap data in vector form suitable for rendering, in GeoJSON and MVT formats.

I’m offering these as an experimental service, if you find them useful let me know. Read more about tiled vector data on my blog.

Status:

Layers

Road Lines

OpenStreetMap roads, highways, railways and paths matching the selection found in High Road. Sort them with sort_key to correctly represent layered overpasses, bridges and tunnels. Try the kind property for a three-part scale-dependent classification of roads into highway, major_road and minor_road.

Template & GeoJSON

http://tile.openstreetmap.us/vectiles-highroad/{z}/{x}/{y}.mvt
http://tile.openstreetmap.us/vectiles-highroad/12/656/1582.json

Properties: highway, railway, kind (highway, major_road, minor_road, rail, path), is_bridge (yes, no), is_tunnel (yes, no), is_link (yes, no), sort_key (numeric).

Clipped.

Mapnik XML Sample

<Datasource>
  <Parameter name="type">python</Parameter>
  <Parameter name="factory">TileStache.Goodies.VecTiles:Datasource</Parameter>
  <Parameter name="template">http://tile.openstreetmap.us/vectiles-highroad/{z}/{x}/{y}.mvt</Parameter>
  <Parameter name="sort_key">sort_key</Parameter>
</Datasource>

Carto MML Sample

{
  "type": "python",
  "factory": "TileStache.Goodies.VecTiles:Datasource",
  "template": "http://tile.openstreetmap.us/vectiles-highroad/{z}/{x}/{y}.mvt",
  "sort_key": "sort_key"
}

Road Labels

OpenStreetMap-derived, generalized and simplified street names using the Streets and Routes data set. At lower zoom levels, uses shortened street names for more compact labeling.

Template & GeoJSON

http://tile.openstreetmap.us/vectiles-skeletron/{z}/{x}/{y}.mvt
http://tile.openstreetmap.us/vectiles-skeletron/12/656/1582.json

Properties: highway, name, sort_key (numeric).

Unclipped.

Mapnik XML Sample

<Datasource>
  <Parameter name="type">python</Parameter>
  <Parameter name="factory">TileStache.Goodies.VecTiles:Datasource</Parameter>
  <Parameter name="template">http://tile.openstreetmap.us/vectiles-skeletron/{z}/{x}/{y}.mvt</Parameter>
  <Parameter name="clipped">false</Parameter>
  <Parameter name="sort_key">sort_key</Parameter>
</Datasource>

Carto MML Sample

{
  "type": "python",
  "factory": "TileStache.Goodies.VecTiles:Datasource",
  "template": "http://tile.openstreetmap.us/vectiles-skeletron/{z}/{x}/{y}.mvt",
  "clipped": "false",
  "sort_key": "sort_key"
}

Buildings

Polygons from OpenStreetMap representing building outlines.

Template & GeoJSON

http://tile.openstreetmap.us/vectiles-buildings/{z}/{x}/{y}.mvt
http://tile.openstreetmap.us/vectiles-buildings/12/656/1582.json

Properties: none.

Unclipped.

Mapnik XML Sample

<Datasource>
  <Parameter name="type">python</Parameter>
  <Parameter name="factory">TileStache.Goodies.VecTiles:Datasource</Parameter>
  <Parameter name="template">http://tile.openstreetmap.us/vectiles-buildings/{z}/{x}/{y}.mvt</Parameter>
  <Parameter name="clipped">false</Parameter>
</Datasource>

Carto MML Sample

{
  "type": "python",
  "factory": "TileStache.Goodies.VecTiles:Datasource",
  "template": "http://tile.openstreetmap.us/vectiles-buildings/{z}/{x}/{y}.mvt",
  "clipped": "false"
}

Points of Interest

Points of Interest from OpenStreetMap, based on per-zoom selections from the primary OSM.org Mapnik stylesheet.

Template & GeoJSON

http://tile.openstreetmap.us/vectiles-pois/{z}/{x}/{y}.mvt
http://tile.openstreetmap.us/vectiles-pois/12/656/1582.json

Properties: name, kind (a combination of aerialway, aeroway, natural, railway, tourism and other tags).

Mapnik XML Sample

<Datasource>
  <Parameter name="type">python</Parameter>
  <Parameter name="factory">TileStache.Goodies.VecTiles:Datasource</Parameter>
  <Parameter name="template">http://tile.openstreetmap.us/vectiles-pois/{z}/{x}/{y}.mvt</Parameter>
</Datasource>

Carto MML Sample

{
  "type": "python",
  "factory": "TileStache.Goodies.VecTiles:Datasource",
  "template": "http://tile.openstreetmap.us/vectiles-pois/{z}/{x}/{y}.mvt"
}

Land Usages

Polygons from OpenStreetMap representing parks, forests, residential, commercial, industrial, cemetery, golf course, university, schools, sports and other areas. Derived from a combination of the tags landuse, leisure, natural, highway, and amenity.

Template & GeoJSON

http://tile.openstreetmap.us/vectiles-land-usages/{z}/{x}/{y}.mvt
http://tile.openstreetmap.us/vectiles-land-usages/12/656/1582.json

Properties: kind, name, area (numeric).

Unclipped.

Mapnik XML Sample

<Datasource>
  <Parameter name="type">python</Parameter>
  <Parameter name="factory">TileStache.Goodies.VecTiles:Datasource</Parameter>
  <Parameter name="template">http://tile.openstreetmap.us/vectiles-land-usages/{z}/{x}/{y}.mvt</Parameter>
  <Parameter name="clipped">false</Parameter>
</Datasource>

Carto MML Sample

{
  "type": "python",
  "factory": "TileStache.Goodies.VecTiles:Datasource",
  "template": "http://tile.openstreetmap.us/vectiles-land-usages/{z}/{x}/{y}.mvt",
  "clipped": "false"
}

Water Areas

Polygons from OpenStreetMap representing oceans, riverbanks and lakes. Derived from a combination of the tags waterway, natural, and landuse. Includes coastline-derived water polygons from openstreetmapdata.com.

Template & GeoJSON

http://tile.openstreetmap.us/vectiles-water-areas/{z}/{x}/{y}.mvt
http://tile.openstreetmap.us/vectiles-water-areas/12/656/1582.json

Properties: kind, name, area (numeric).

Unclipped.

Mapnik XML Sample

<Datasource>
  <Parameter name="type">python</Parameter>
  <Parameter name="factory">TileStache.Goodies.VecTiles:Datasource</Parameter>
  <Parameter name="template">http://tile.openstreetmap.us/vectiles-water-areas/{z}/{x}/{y}.mvt</Parameter>
  <Parameter name="clipped">false</Parameter>
</Datasource>

Carto MML Sample

{
  "type": "python",
  "factory": "TileStache.Goodies.VecTiles:Datasource",
  "template": "http://tile.openstreetmap.us/vectiles-water-areas/{z}/{x}/{y}.mvt",
  "clipped": "false"
}