SQLite format for osmdroid
Brought to you by:
r_x
I recently implemented a sqlite storage for the tiles of the osmdroid lib, and the only thing missing is the ability to create it with mobac. So I wrote this patch to provide the new output option. Please have a look and commit it if you like it. Let me know if you think I should change something.
View and moderate all "patches Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Patches"
OsmdroidSQLite patch
Is it true that Osmdroid supports all available projections of MOBAC and all tile sizes?(testMapSource returns true). Currently this means that Mercator SPHERE and ELLIPSOID projections and tile sizes of 256x256 and 512x512 can be used?
Additionally I noticed the "index calculation" my overflow for high zoom levels:
int index = (((zoom << zoom) + x) << zoom) + y;
Is an integer overflow in the index intentionally or a problem (MAX_ZOOM = 22)?
View and moderate all "patches Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Patches"
For the first question, osmdroid supports "CloudMadeSmallTiles", which is a source with 64x64 tiles. Concerning the projection though, the current implementation in mobac of zip files for osmdroid does indeed only accept SPHERE, so maybe it's a good idea to restrict to that. For the second question, you're totally right, we should use a "long" and add all the necessary casts. I'm on my way to correct that in osmdroid.
View and moderate all "patches Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Patches"
second OsmdroidSQLite patch
View and moderate all "patches Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Patches"
I posted a new patch correcting the 2 issues
I applied the second patch. But I saw another problem. You are creating one batch for each map which will on large maps result in an OutOfMemoryError. I know what I am talking about RMapsSQLite suffered (in the past) from multiple problems leading to the same error.
I added the necessary changes as well as the missing progress bar for the GUI - see latest version in SVN.
View and moderate all "patches Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Patches"
Thank you ! It's good to create maps in sqlite with a gui...