'm trying to create an app that contains a small map that should always work without internet connection for four different zoom levels. To do this i know that i have to generate map tiles in png (or similar) to be used later on by Leaflet (or Open Layer/Mapbox GL JS) . This is no issue, because using Maperitive i can generate map tiles with given bounds and min and max zoom levels.
My problem is that i need to use a different style for roads, buildings, etc. To edit this style i used Mapbox Studio online editor and generated a JSON file with my custom styles.
What i need to do is apply this style before generating the resulting tiles, but i don't know how to do this. Below there's a diagram for what i'm thinking about.
asked 18 Apr, 19:38
The Mapbox Studio style json is used to visually render Mapbox vector tiles in the browser using Mapbox GL JS. There is no mechanism to convert these into the png tiles that you are expecting unfortunately.
Your best bet might be to create multiple maperitive styles and generate the tiles.
answered 19 Apr, 08:58