Results 1 to 6 of 6

Thread: Help with offline bundle maps

  1. #1
    Neuer skobbler
    Join Date
    12.01.2016
    Posts
    4

    Help with offline bundle maps

    Hello Skobbler community

    I am trying to implement a bundled offline map functionality in my app. I want the user to be able to switch between a couple of pre-downloaded maps that are bundled in the app from the start. I have read your documentation about this subject, but I cant't really grasp how to implement it.

    For example if I place my downloaded maps in the PreinstalledMaps/v1/20150413/package/ folder, what is the path that the function addOfflineMapPackageNamed need?
    Also the folder where the application lies on the simulator, for example, changes path with every build of the application. How can you get an static path?

    I would really like some help with a code example in swift how to do this.

    Thanks for the help!
    Last edited by martinhiq; 12.01.2016 at 16:47.

  2. #2
    Etablierter skobbler
    Join Date
    11.04.2015
    Posts
    41
    http://developer.skobbler.com/getting-started/ios#sec31

    You don't need to call addOfflineMap... when you have those files in your .zip (at least in Android) ..

    Everything should work fine this way .. just remember that you need not only .skm files in your package folder, but also .ngi, .ngi.dat, .txg as well ..

  3. #3
    Oberskobbler
    Join Date
    22.07.2014
    Posts
    399
    Thanks mz87 for the answer!
    Additional information: for the offline packages, the only mandatory file is the .skm. The ".ngi" and ".ngi.dat" are used only for searches, and the ".tgx "textures are used for better display of a country on a high zoom level.

  4. #4
    Neuer skobbler
    Join Date
    12.01.2016
    Posts
    4
    Thanks! I have successfully added the prebundled maps and it works great.

    One question though, when i flip connectivityMode from offline to online the caching of the map acts weird (on country maps that are not prebundled).
    Roads that are in the viewable map will not load and street addresses will not be drawn.

    Is there something else I have to do when going from offline to online?


    EDIT: I was in SKMapDetailLevel.Light, that seams to be the problem.

    Put now another question has arose, I have added: map.settings.poiDisplayingOption.remove(.Important ), but the POI are still showing on the map. Is there something else that I need to add to remove POIs?
    Last edited by martinhiq; 27.01.2016 at 11:21.

  5. #5
    Neuer skobbler
    Join Date
    12.01.2016
    Posts
    4
    I fiddled around with the POI some more and now I have it configured the way I wanted to.

  6. #6
    Oberskobbler
    Join Date
    22.07.2014
    Posts
    399
    Using the light maps "SKMapDetailLevelLight" you won't have POI data and the maps will be smaller in size.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •