![]() * Update gradle wrapper to 6.8.3 * Remove incompatible build instructions * Replace deprecated findbugs with spotbugs * Remove jDepend, there is no close approximation replacement * Update left shift to be doLast * Add compileSdkVersion to projects * Update travis configuration to support more recent build tools * #1776 made some progress with the build tech update - dist zip is not hooked up - maven central publishing definitely needs to be redone, from scratch - mil-sym-android was on bintray but that is dead now, so if you attempt to build this branch, you'll check to check out and build that repo * #1776 javadocs are now generated from the aar (although a bit of a hack) * #1776 moves apk signing config to a new file updates 2525 renderer to a version that is on central * #1776 first successful test publish of snapshots and a release run (FOR AAR's ONLY) caveats, dependency declarations in the poms are done by parsing build.gradle files which is super risky considering the massive variations for writing them. exclusions aren't applied yet * #1776 all jar, war components are now published. Found a number of security issues identifed by sonatype lift when publishing thus the many dependency updates. At this point, i think it's good enough for PR and hopefully for some assistance to resolving the on device unit testing stuff that's broken and the one or two unit tests that stopped working and is now commented out. Wiki release procedure document needs to be updated as well * #1776 reverting previous disabled functions that failed for unknown reasons during the upgrades. seems to work ok now though * #1776 removing the old projects from version control, they have been incompatible for nearly 4 years now * #1776 no longer needed since we no longer have any closed source libraries * #1776 removing the quality plugin, none of the operations in there still work with the newer android stuff adding in @hannesa2's github action scripts to ci osmdroid again * #1776 no longer needed submodule reference, updating ci build * #1776 borrowing more from fury, should resolve ci issues * #1776 borrowing more from fury, should resolve ci issues * #1776 borrowing more from fury, should resolve ci issues, got it this time * #1776 removing the checkstyle, qualty plugin was removed Co-authored-by: Al Sutton <al.sutton@alsutton.com> |
||
---|---|---|
.. | ||
src | ||
ui/native/19/osx-amd64 | ||
build.gradle | ||
fr_mapnik_12.gemf | ||
fr_mapnik_12.sql | ||
fr_mapnik_12.zip | ||
readme.md |
OSM Map Tile Packager
Why would you want to use this?
Caching tiles for offline/disconnect use
Any legal issues?
Plenty, make sure you read the tile usage agreement from whomever you cache tiles from. Many tile sources do not allow via their license agreements.
What sources can I use with this?
Any map source (baring legal issues) that uses the Z/X/Y tile naming convention.
Any examples?
Tons. keep reading.
What output files can this produce?
Osmdroid style zip, sqlite and GEMFile databases.
OK I downloaded the internet, what do I do with the output file?
Copy the output file to /sdcard/osmdroid/. Then tell Osmdroid to use the correct map source. See below for an important note...
I deployed the zip but no tiles are displaying. What's wrong?
You probably missed the 'important note' section.
Any known issues?
Check the issue tracker. There's also issues when using the entire planet as your download set, whereby the tile bound calculations produce strange results (negative y indexes). Try a smaller bounding box.
How do I use this?
Open a command line/terminal/bash shell
java -jar osmdroid-packager-<VERSION>-jar-with-dependencies.jar -u url -t <MapSourceName> -d <outputfile.zip> -zmin <MIN ZOOM> -zmax <MAX ZOOM up to 22> -n <NORTH> -s <SOUTH> -e <EAST> -w <WEST> -nthreads <optional, number of current threads, default 2> -fa <optional file extension add on, not really needed>1
All bounds are in decimal degrees latitude/longitude.
Important note
Here's a few usage examples. There's a few caveats that you must follow if you want these tiles to show up in OsmDroid.
- The temporary folder to save files should be named the name of your map source.
- In OsmDroid, set the map source's name equal to the temporary folder name.
java -jar ....-jar -t <name of map source here> -d outputfile
Example: Open Streem Map tiles (Mapnik)
java -jar ....jar -u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d at_mapnik_13.zip -zmax 13 -n 49.03942 -s 46.40162 -e 17.14736 -w 9.44595
^ that's the important part!
More reading
https://github.com/osmdroid/osmdroid/wiki/Offline-Map-Tiles
https://github.com/osmdroid/osmdroid/wiki/Map-Sources
More examples
Austria, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d at_mapnik_13.zip -zmax 13 -n 49.03942 -s 46.40162 -e 17.14736 -w 9.44595
Sweden, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d se_mapnik_12.zip -zmax 12 -n 69.05567 -s 55.18336 -e 24.31045 -w 11.17080
Germany, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d de_mapnik_12.zip -zmax 12 -n 54.9174 -s 47.281101 -e 15.03805 -w 5.869443
Germany, Berlin(wider area), Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d de_berlin_mapnik_15.zip -zmax 15 -n 52.80 -s 52.24 -e 13.94 -w 12.80
BeNeLux, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d benelux_mapnik_13.zip -zmax 13 -n 53.59187 -s 49.44601 -e 7.25555 -w 2.35564
Utrecht, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d nl_utrecht_mapnik_16.zip -zmax 16 -n 52.161593 -s 52.045820 -e 5.189602 -w 4.988071
France
France, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d fr_mapnik_12.zip -zmax 12 -n 51.091099 -s 41.366379 -e 9.543055 -w -4.790556
Paris, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d fr_paris_mapnik_15.zip -zmax 15 -n 49.07002 -s 48.60997 -e 2.87887 -w 1.85302
Czech Republic, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d cz_mapnik_13.zip -zmax 13 -n 51.08776 -s 48.54 -e 18.87222 -w 12.049
Ireland, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d ie_mapnik_13.zip -zmax 13 -n 55.37187 -s 51.40497 -e -5.35950 -w -10.67689
UK
UK, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d uk_mapnik_12.zip -zmax 12 -n 58.62459 -s 49.87227 -e 1.73766 -w -8.23792
London, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d uk_london_mapnik_15.zip -zmax 15 -n 51.73360 -s 51.25223 -e 0.30257 -w -0.60105
Spain, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d es_mapnik_12.zip -zmax 12 -n 43.77677 -s 36.05546 -e 4.34829 -w -9.31870
Poland, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d pl_mapnik_12.zip -zmax 12 -n 54.85584 -s 48.94210 -e 24.21157 -w 14.08218
Italy, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d it_mapnik_13.zip -zmax 13 -n 47.09792 -s 36.63066 -e 18.53164 -w 6.64443
Switzerland, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d ch_mapnik_13.zip -zmax 13 -n 47.82581 -s 45.80365 -e 10.55007 -w 5.59779
Portugal
Portugal, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d pt_mapnik_13.zip -zmax 13 -n 42.17330 -s 36.95179 -e -6.18760 -w -9.51646
Lisboa, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d pt_lisbon_mapnik_17.zip -zmax 17 -n 38.83006 -s 38.63616 -e -9.09623 -w -9.30016
Porto, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d pt_porto_mapnik_17.zip -zmax 17 -n 41.22138 -s 41.06004 -e -8.56271 -w -8.70587
USA
USA, Mapnik
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d us_mapnik_11.zip -zmax 11 -n 49.15093 -s 24.84373 -e -66.67832 -w -124.90586
USA, Manhattan
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d us_manhattan_mapnik_17.zip -zmax 17 -n 40.83197 -s 40.69545 -e -73.87409 -w -74.06223
USA, Washington D.C.
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d us_washingtondc_mapnik_17.zip -zmax 17 -n 38.99648 -s 38.80143 -e -76.90797 -w -77.17370
USA, San Francisco(specificly), Mapnik, MaxZoom=17, for AndNav2
-u http://b.tile.openstreetmap.org/%d/%d/%d.png -t Mapnik -d us_sanfrancisco_mapnik_17.zip -zmax 17 -n 37.811976 -s 37.699600 -e -122.345098 -w -122.521050