Tripwire
Tripwire

Reputation: 198

OSMDroid Offline map with zip from custom server

I'm having a really hard time to get OSMDroid working with our custom tile server. I'm getting our tiles in a zip file which has the following structure: ZoomLevel/Y/X

I've tried unzipping the zip to the osmdroid/tiles folder and the osmdroid/tiles/Mapnik folder but none of them seem work. I think I need to use the FileBasedTileSource but I don't know what to put in the aName and URL part of the method.

I'm trying to download specific areas as a zip file for use in offline situations, which on Google Maps works perfectly but I want to try out OSMDroid and see of the performance is better.

Can anyone give me some pointers on how to get this working?

Upvotes: 1

Views: 301

Answers (1)

spy
spy

Reputation: 3258

Zip archives for osmdroid must have the following structure {Source}/Z/X/Y.{extension}

Then tell osmdroid to use a tile source whose name matches exactly {Source}. Everything should be automatic.

Also, consider using sqlite database, they are generally faster

Upvotes: 1

Related Questions