Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

OSM offline map in Windows using offline tile server



  • I am trying to display offline map in QT using offline tile server in windows 7 PC. I have followed the procedure from the link “https://openmaptiles.com/server”.

    1. Enabled Virtualization in bios settings and Installed Docker Toolbox 18.03.0-ce.
    2. Since my pc is not connected to internet i have downloaded “klokantech/opemmaptiles-server” - docker image in internet PC and loaded into my offline pc using "docker load" command.
    3. Using Kitematic application i started the openmaptiles-server container with the host address "192.168.99.100:32772". Copied "mbtiles" file in /data folder path.
      Test_3.jpg
    4. When i opened "192.168.99.100:32772" in the firefox browser i am able to see the map without any problem.
    5. I have downloaded the minimal map example code and tested in both internet and offline PC and it was working fine.
      Test_1.jpg
    6. Now, i have modified the Plugin lines as below in main.qml of the minimal map example code to view the offline map,
      Plugin {
      id: osmPlugin
      name: "osm"
      PluginParameter { name: "osm.useragent"; value: "My name" }
      PluginParameter { name: "osm.mapping.host"; value: "http://192.168.99.100:32772/" }
      PluginParameter { name: "osm.mapping.copyright"; value: "My Name" }
      PluginParameter { name: "osm.mapping.providersrepository.disabled"; value: true }
      }

    My Issue is When i run this code in offline PC it shows blank page. But when i run the same code in the internet PC without any offline server(docker) it shows map.
    Please guide me to resolve this issue. Note : Offline PC will never be connected to internet

    Test_4.jpg


Log in to reply