openmaptiles/style
Andrea Mennillo 2f170fbbd8
Improve poi shop style (#1634)
The main goal is to improve consistency and reduce the number of poi without an icon.

- Remove music from poi cultural, music has only two subclasses music and musical_instrument, both are styled as poi shop
- Remove arts_centre from poi shop, it's already styled as poi cultural
- Remove chocolate icon, chocolate uses confectionery icon (see: https://github.com/openmaptiles/openmaptiles/pull/1628)
- Remove references to ice_cream class from poi shop
- Add missing gallery icon and move it to poi cultural (see: https://wiki.openstreetmap.org/wiki/Tag:tourism%3Dgallery)
- Use the icons alcohol, newsagent, perfumery, trade respectively for wine, kiosk, perfume and wholesale.
- Add a generic fallback icon for shops
2024-02-21 16:25:54 +01:00
..
icons Improve poi shop style (#1634) 2024-02-21 16:25:54 +01:00
README.md
config.json
style-header.json

README.md

OSM OpenMapTiles style

OSM OpenMapTiles is the official style of OpenMapTiles. Its purpose is to display all features in vector tiles.

OSM OpenMapTiles style is heavily inspired by OSM Carto.

Huge credit belongs to the original authors.

Fonts

OSM OpenMapTiles style used Noto Sans fonts. To download these fonts run:

make download-fonts

It downloads Noto Sans fonts (~70MB) and extract them into openmaptiles/data/fonts directory.

Icons/sprite

All icons which are used OpenMapTiles style are located in openmaptiles/style/icons. After the style is built, the icons are composed into sprite files located in build directory.

Additional svg icons can be added to openmaptiles/style/icons directory.

To generate new sprite files with added icons, run:

make build-sprite

Sprite files will be generated into build directory.

OSM Icons

Icons in the OSM OpenMapTiles style are based on original OSM Carto symbols.

The original icons can be found in openstreetmap-carto/symbols.

Icons used in OSM OpenMapTiles style were scaled down and saved as svg.

Build style

To build style run:

make build-style

It generates new sprite files and merges all style snippets from each layer, orders them according the order value and saves the complete style into build/style/style.json.

Tileserver-gl

The tileserver serves both the tiles and the OSM OpenMapTiles map.

MBTiles (default)

By default, the tileserver serves OSM OpenMapTiles map based on tiles from data/tiles.mbtiles as defined in style-header.json.

"sources": {
  "openmaptiles": {
    "type": "vector",
    "url": "mbtiles:///data/tiles.mbtiles"
  },
  ...
}

Serve from the db

The tileserver can also serve OSM OpenMapTiles map based on dynamically generated tiles directly from the database. Start the database container and the postserve container:

make start-db
make start-postserve

In style-header.json change the source of tiles to PostServe:

Start tileserver

Before you start the tileserver, make sure you have fonts downloaded in openmaptiles/data/fonts, sprites generated and style built:

make download-fonts
make build-style

Start tileserver:

make start-tileserver

And go to http://localhost:8080.