maptiler / tileserver-gl

Vector and raster maps with GL styles. Server side rendering by MapLibre GL Native. Map tile server for MapLibre GL JS, Android, iOS, Leaflet, OpenLayers, GIS via WMTS, etc.
https://tileserver.readthedocs.io/en/latest/
Other
2.22k stars 637 forks source link

tileserver-gl does not work with mbtiles from http://osmlab.github.io/osm-qa-tiles/ #448

Open sherpya opened 4 years ago

sherpya commented 4 years ago

I'm using tileserver-gl v3.0.0 with node v10.20.1

It works fine using osm-2017-07-03-v3.6.1-europe_italy.mbtiles

but not with maps downloaded from http://osmlab.github.io/osm-qa-tiles/

I only get white (or black depending on the theme) tiles

here is my config:

{
  "options": {
    "paths": {
      "root": "",
      "fonts": "fonts",
      "styles": "styles",
      "mbtiles": "mbtiles"
    },
    "domains": [
      "localhost:8080",
      "127.0.0.1:8080"
    ],
    "formatQuality": {
      "jpeg": 80,
      "webp": 90
    },
    "maxScaleFactor": 3,
    "maxSize": 1024,
    "pbfAlias": "pbf",
    "serveAllFonts": false,
    "serveAllStyles": false,
    "serveStaticMaps": true,
    "tileMargin": 0
  },
  "styles": {
    "dark-matter": {
      "style": "dark-matter-gl-style/style-local.json"
    },
    "positron": {
      "style": "positron-gl-style/style-local.json"
    }
  },
  "data": {
    "v3": {
      "mbtiles": "osm-2017-07-03-v3.6.1-europe_italy.mbtiles"
    },
    "_": {
      "mbtiles": "italy.mbtiles"
    }
  }
}
hfs commented 4 years ago

Vector tiles have a schema which defines which layers are found in the data and what attributes they have. The style used to render the data in the client accesses the layers and attributes and defines how to draw them using lines, colors, etc.

The usual styles for tileserver-gl like positron use the OpenMapTiles schema. The OSM QA Tiles use an entirely different schema, that is not geared towards map making, but to provide all information to data processing tools. That’s why the style rules in positron don’t find the data they are looking for in the QA Tiles.

You would need to create a style from scratch to visualize the QA data. Here’s some discussion about using the Maputik editor for this task (without solution): https://github.com/maputnik/editor/issues/83

sherpya commented 4 years ago

@hfs there is a converter docker image but e.g. Italy map at zoom 7-16 (or 18) would take 80 days even on a very performant box