Search code examples
androidmbtiles

How to use an mbtiles database with Android TileProvider?


What is the best way to use an mbtiles database with google's TileProvider?

I've been told that tiles as files are difficult to manage so i'm trying to use the mbtiles directly.


Solution

  • Take a look here: https://github.com/cocoahero/android-gmaps-addons/blob/master/src/com/cocoahero/android/gmaps/addons/mapbox/MapBoxOfflineTileProvider.java

    That class will do it for you.

    I hope you can use it.