Questions tagged [mbtiles]

MBTiles is a file format for storing map tiles in a single file. It is, technically, a SQLite database. Latest format version as of February 2018 is 1.3.

Tile based web maps are made up of millions of tiles. Imagine loading all of those tiles; it would be inefficient and slow. That’s where MBTiles comes in. The MBTiles specification is an efficient format for storing millions of tiles in a single SQLite database.

SQLite is ideal for serving tiles on the web or displaying directly on mobile devices because it’s used on so many platforms. If you’ve worked with SQL databases before, SQLite should feel very familiar. With SQLite, each database is self-contained and represented as a single .sqlite file. There’s no external setup required. You can copy a .sqlite file from desktop to a mobile device and have all its rows, tables, and indexes ready to be used. It’s a portable, single-file solution for storing and serving web maps.

MBTiles takes advantage of utilities found in SQLite for solving problems like duplicate imagery. Maps that cover large areas of solid color like ocean or empty land can contain thousands of duplicate, redundant tiles.

For more

http://wiki.openstreetmap.org/wiki/MBTiles

https://www.mapbox.com/help/an-open-platform/#mbtiles-in-action

169 questions
3
votes
1 answer

Load local .mbtiles with maplibre-gl-js

I want to load a local .mbtiles (with vector tiles) with maplibre-gl-js (in a Cordova app if it's important to know). As far as I understand, I should use the addProtocol method. That works fine as I get my console.log, but I don't know how to load…
Hollul
  • 319
  • 4
  • 16
3
votes
1 answer

tippecanoe keeps dropping polygons at mid level zooms

Is there anyway to stop tippecanoe from dropping polygons at low/mid level zooms while keeping within the 500kb per tile size limit of mapbox uploads for an mbtiles file? We are getting a lot of polygons being dropped. We are not sure what flags to…
blg2
  • 355
  • 6
  • 23
3
votes
1 answer

Read openstreetmap PBF file with PHP?

I downloaded a mbtiles file from this location: https://openmaptiles.com/downloads/europe/netherlands/ I can serve this file in PHP with this library : https://github.com/klokantech/tileserver-php This returns a compressed PBF, which Mapbox GL JS…
Dylan
  • 9,129
  • 20
  • 96
  • 153
3
votes
2 answers

can't install mbtiles plugin in geoserver

I am trying to install mbtiles plugin for geoserver 2.9. I have successfully installed geoserver in tomcat 7.0 (in windows 10). I downloaded geoserver from [http://ares.opengeo.org/geoserver/master/] It works fine without any plugin installed. But…
Rooney
  • 83
  • 7
3
votes
2 answers

Use of MBTiles in offline iOS app

I already have a map stored using the MBTiles format that I want to use in an app I am making. It is vital that the app will run with no signal/connection on the mobile device. Mapbox previously had an example of how to use MBTiles together with…
Welly
  • 305
  • 6
  • 21
3
votes
1 answer

mbtiles: Is it possible to draw some lines on offline mbtiles map

I have an .mbtiles file and I am using it for offline map (iOS MapBox SDK). But my .mbtiles doesn't have enough data (just simple green rectangle). I want to draw some lines(roads) between points (I download it from my rest API). I found the…
Artem Z.
  • 1,243
  • 2
  • 14
  • 36
2
votes
2 answers

`require': cannot load such file -- rack/handler (LoadError)

I'm not a Ruby person, so this may be a 101 question. I'm just trying to use a utility that happens to be written in Ruby. I'm using tilemaker, a utility in the openstreetmap ecosystem. It creates tiles in the mbtiles format. The repository comes…
orblivion
  • 446
  • 3
  • 12
2
votes
0 answers

Android: is it possible to query mbtiles database in android platform

I use the vector mbtiles database in my Android project. It contains some list of Features. I use this mbtiles as a data source for Vector Layer at Mapbox. At the same time I need to get this list of Features without using Mapbox. Is it possible to…
user2775914
  • 193
  • 1
  • 9
2
votes
0 answers

How to configure GeoServer to use .mbtiles osm map with the mb styles (map box styles)

I am setting up GeoServer v2.20 to use .mbtiles osm(OpenStreetMap) vector tiles map file with the map box styles (style.json). Able to enable the MBTiles Store and MBStyle options by adding the corresponding extension for MBTiles & MBStyle in…
Coder4Jsf
  • 31
  • 3
2
votes
0 answers

Storage-optimizing sqlite blob to act as data or foreign key

Is there a storage and performance gain to denormalize sqlite3 blob column into primary table, but treat it as a foreign key only in some cases? I have two implementations, and both seem to run slower. Is there some sqlite3 internals that preclude…
Yuri Astrakhan
  • 8,808
  • 6
  • 63
  • 97
2
votes
0 answers

How to overlay a satellite mbtiles over a regular OSM map?

I'm using klokantech tileserver gl to serve OSM maps. These maps are consumed by a frontend developed using Vue and vue-leaflet. The OSM world mbtiles file works perfectly with the default config from klokan. An asked evolution of the system is to…
2
votes
0 answers

Mbtiles generation with tippecanoe on a mixed geojson feature file

I have a bunch of geojson files that I want to use to create a .mbtiles file, these geojson files were made by using ogr2ogr on a .osm.pbf file. Though these files seemed to have mixed features within them, e.g. the linestring.geojson file has…
MacaScull
  • 161
  • 1
  • 10
2
votes
0 answers

How to avoid compression when converting GeoTIFF to MBTiles?

I have been trying to convert a set of GeoTIFF files into MBTiles using gdal_translate (GDAL 3.0.4). My command looks as follows: gdal_translate -of MBTiles -ot Byte -strict -scale 0 255 bogota.tif bogota.mbtiles The GeoTIFF image is successfully…
Filip Östermark
  • 311
  • 2
  • 15
2
votes
1 answer

Offline map without a tile server

Tell me, please, I need to create an application that without the Internet will load an (offline) map of some area and it will be possible to indicate the path on it with points (points will be anchored to latitude and longitude coordinates). Tile…
Thr0TT1e
  • 35
  • 4
2
votes
0 answers

Merge multiple Raster MBTiles (Sqlite file) through commandline

I have 50 mbtiles files which is in Raster format. mbtiles file is basically an SQLite file. I have successfully merged them through SQLite IDE using the following query. ATTACH 'path/to/db2.mbtiles' AS db2; INSERT OR REPLACE INTO map SELECT * from…
Devil's Dream
  • 655
  • 3
  • 15
  • 38
1
2
3
11 12