[Marble-devel] Marble with offline OSM maps

Dennis Nienhüser earthwings at gentoo.org
Tue May 15 12:41:33 UTC 2012


Hi Jeremie,

Am 15.05.2012 14:29, schrieb Jeremie Scheer:
> Thanks for your answers.
>
> I'm a beginner with map and geolocalization tools, so there are many 
> things I still don't know.
>
>> You might want to default to Mercator projection in Marble since that 
>> delivers
>> the best speed.
> How can you do that ? Is there a method in the code to default to 
> Mercator ?

Yes, MarbleWidget::setProjection(); See [1] for a code example.

>
>> It's trivially easy to preload the tiled bitmaps
> Where can you find tiled bitmaps from OSM on the Internet ? Or OSM 
> files must be transformed to tiled bitmaps with Mapnik first ?
>
>
> Now if I have tiled bitmaps, how can I use them in Marble library 
> being offline ?
>
> Regards,

The easiest way is to open Marble as a regular program, select the map 
theme you'd like to use (possibly OpenStreetMap) and use File->Download 
Region to have Marble retrieve the bitmaps for you. They'll end up in 
(for OpenStreetMap) the ~/.local/share/marble/maps/earth/openstreetmap/ 
directory.
You can transfer the contents of the directory to your device and 
they'll be automatically found and used by Marble and also applications 
using Marble as a library (assuming you transfer it to the right 
directory on the device). The directory must not be user specific, you 
can also use Marble's system directory (where openstreetmap.dgml gets 
installed to).

Note however that this approach scales well performance wise, but does 
not scale storage wise to provide map data for the entire planet in 
street zoom level (unless you have several GB available).

Regards,
Dennis

[1] http://techbase.kde.org/Projects/Marble/MarbleMarbleWidget

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/marble-devel/attachments/20120515/36275495/attachment.html>


More information about the Marble-devel mailing list