1️⃣Create A Region
Regions (BaseRegion
s) are geographical areas that do not yet have any of the necessary extra information to start a download (like DownloadableRegion
s).
The Example Application contains a great way you might want to allow your users to choose a region to download, and it shows how to use Provider to share a created region and the number of approximate tiles it has to a download screen. It even allows the user to follow the download, tile-by-tile!
Types Of Region
The most basic type of region, defined by two North West and South East coordinates that create a LatLngBounds
.
This is usually all you get from most apps, so why not give your user a unique experience with some of our other region types...
Interested to see how the tile generation algorithms for the different region types work under the hood, in a visual way?
Start a download in the example app, and tap/click the 'eye' icon in the top-left. Watch as you follow along with the download, tile-by-tile.
After you've created your region, you can convert it to a drawable polygon (below), or convert it to a DownloadableRegion
ready for downloading.
Converting To Drawable Polygons
All BaseRegions
can be drawn on a map with minimal effort from you or the user, using toDrawable()
.
Internally, this uses the toOutline(s)
method to generate the points forming the Polygon
, then it places this/these polygons into a PolygonLayer
.
Last updated