久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    <bdo id='XG2Ng'></bdo><ul id='XG2Ng'></ul>

    1. <i id='XG2Ng'><tr id='XG2Ng'><dt id='XG2Ng'><q id='XG2Ng'><span id='XG2Ng'><b id='XG2Ng'><form id='XG2Ng'><ins id='XG2Ng'></ins><ul id='XG2Ng'></ul><sub id='XG2Ng'></sub></form><legend id='XG2Ng'></legend><bdo id='XG2Ng'><pre id='XG2Ng'><center id='XG2Ng'></center></pre></bdo></b><th id='XG2Ng'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='XG2Ng'><tfoot id='XG2Ng'></tfoot><dl id='XG2Ng'><fieldset id='XG2Ng'></fieldset></dl></div>
      1. <small id='XG2Ng'></small><noframes id='XG2Ng'>

        <tfoot id='XG2Ng'></tfoot><legend id='XG2Ng'><style id='XG2Ng'><dir id='XG2Ng'><q id='XG2Ng'></q></dir></style></legend>

        顯示離線 OSM 映射文件.建議:一個帶有 Js.library 的

        Showing an offline OSM map file. Suggestion: an MB Tiles file with Js.library(顯示離線 OSM 映射文件.建議:一個帶有 Js.library 的 MB Tiles 文件)
        • <small id='pvR1A'></small><noframes id='pvR1A'>

          <tfoot id='pvR1A'></tfoot>
          <i id='pvR1A'><tr id='pvR1A'><dt id='pvR1A'><q id='pvR1A'><span id='pvR1A'><b id='pvR1A'><form id='pvR1A'><ins id='pvR1A'></ins><ul id='pvR1A'></ul><sub id='pvR1A'></sub></form><legend id='pvR1A'></legend><bdo id='pvR1A'><pre id='pvR1A'><center id='pvR1A'></center></pre></bdo></b><th id='pvR1A'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='pvR1A'><tfoot id='pvR1A'></tfoot><dl id='pvR1A'><fieldset id='pvR1A'></fieldset></dl></div>
              <tbody id='pvR1A'></tbody>
            <legend id='pvR1A'><style id='pvR1A'><dir id='pvR1A'><q id='pvR1A'></q></dir></style></legend>

              <bdo id='pvR1A'></bdo><ul id='pvR1A'></ul>

                1. 本文介紹了顯示離線 OSM 映射文件.建議:一個帶有 Js.library 的 MB Tiles 文件的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  當無法在線訪問互聯網時,我希望(離線)HTML5 應用程序通過 OSM 文件顯示 OSM 地圖.

                  When online access to the internet is not possible, I would like the (offline) HTML5 app show an OSM map via an OSM file.

                  您能否舉例說明如何在離線 Html5 應用程序中顯示從離線 OSM 地圖文件(如 Mapsforge/Geofabrik 等)加載的 OSM 切片?

                  Can you give an example of how I can show in an offline Html5 app OSM tiles that are loaded from an offline OSM map file like Mapsforge / Geofabrik etc?

                  示例:我首先通過 openstreetmap.org 導出了一小部分地圖.如何在 Html5 離線 webapp 中顯示這個下載的 OSM 地圖.

                  Example: via the openstreetmap.org I first exported a small part of a map. How can I show this downloaded OSM map in the Html5 offline webapp.

                  推薦答案

                  我們如何使用 Leaflet 顯示地圖?默認情況下,Leaflet 適用于光柵圖像.通常,這些圖塊是通過 Internet 檢索的.

                  How can we show a map using Leaflet? By default Leaflet works with raster images. Normally these tiles are retrieved via the internet.

                  我們如何使用離線文件顯示地圖?例如.因為沒有互聯網連接是可能的?

                  How can we show a map using an offline file? E.g. because no internet connection is possible?

                  1. 層次結構中的局部圖塊.例如通過使用這樣的腳本.缺點是這不是一種緊湊的格式.它需要一些準備工作:

                  1. Local tiles in an hierarchy structure. For example by using such a script. The disadvantage is that this is not a compact format. It requires some preparational work:

                  L.tileLayer('/map-tiles/{z}/map_{x}_{y}.png', {attribution: '地圖數據 ©???',}).addTo(地圖);

                  L.tileLayer('/map-tiles/{z}/map_{x}_{y}.png', { attribution: 'Map data © ???', }).addTo(map);

                  帶有光柵圖塊的 MBTiles 文件.這樣的文件可以通過 Leaflet.TileLayer.MBTiles.js 插件顯示.下面顯示了一個示例腳本.

                  MBTiles file with raster tiles. Such a file can be shown via the Leaflet.TileLayer.MBTiles.js plugin. An example script is shown below.

                  VectorGrid 是閱讀的緊湊候選MBTiles 文件中的矢量數據.另請參閱此說明.

                  Mapbox GL JS 離線.在這種情況下,您將矢量文件放在本地.請參閱 演示.

                  Mapbox GL JS offline. In that case you put locally your vector files. See the demo.

                  mobac.sourceforge.net 正如@JaakL 所建議的那樣.

                  mobac.sourceforge.net as suggested below by @JaakL.

                  廣告選項 3:OpenMapTiles.com 生成非常緊湊的矢量格式 MBTiles 文件.因此,此解決方案對選項 3 很有用.

                  Ad option 3: OpenMapTiles.com generates very compact MBTiles file with the Vector format. So, this solution is useful for option 3.

                  廣告選項 2:當您有 MBTILES/Raster 文件時,以下代碼將正常工作.因此,它不適用于上述 MBTiles 矢量文件.

                  Ad option 2: When you have an MBTILES/Raster file, then the following code will work correctly. So, it is not working with the above MBTiles vector file.

                  • 獲取 TileLayer,包括演示:https://www.npmjs.com/package/Leaflet.TileLayer.MBTiles
                  • 獲取一個示例 MBTile 文件:例如https://openmaptiles.org/downloads/#city ...然后選擇阿姆斯特丹
                  • Get the TileLayer including demo: https://www.npmjs.com/package/Leaflet.TileLayer.MBTiles
                  • Get an example MBTile file: e.g. https://openmaptiles.org/downloads/#city ... and select Amsterdam

                  在使用 npm 大約 1 分鐘安裝包后,我運行了演示.演示位于node_modulesLeaflet.TileLayer.MBTilesdemo"文件夾下.工作正常.

                  After installing in about 1 minute with npm the package I ran the demo. The demo is under the 'node_modulesLeaflet.TileLayer.MBTilesdemo' folder. Works fine.

                  然后我嘗試展示阿姆斯特丹地圖.唉,我無法讓這個(作為新手)工作.我正在為 POC 調查此問題.

                  Then I tried to show the Amsterdam map. Alas, I couldn't get this (as a newbie) working. I am investigating this for a POC.

                  如何更新此來源以顯示阿姆斯特丹地圖?完成它將給予+50賞金.

                  How can I update this source to get the Amsterdam map shown? Getting it done will give the +50 bounty.

                  <!DOCTYPE html>
                  <html>
                  <head>
                  <link  rel="stylesheet" type="text/css" />
                  <script src="https://unpkg.com/leaflet@1.0.0/dist/leaflet-src.js"></script>
                  <script src="https://unpkg.com/sql.js@0.3.2/js/sql.js"></script>
                  <script src="../Leaflet.TileLayer.MBTiles.js"></script>
                    <meta charset="utf-8">
                    <title>Leaflet.TileLayer.MBTiles demo</title>
                    <style>
                      #map {
                        width:600px;
                        height:400px;
                      }
                    </style>
                  </head>
                  <body>
                    <div id='map'></div>
                    <script>
                      var map = new L.Map('map');
                      map.setView(new L.LatLng(52.361367, 4.923083), 18);
                      var mb = L.tileLayer.mbTiles('./amsterdam_netherlands.mbtiles', {
                          minZoom: 16,
                          maxZoom: 20
                      }).addTo(map);
                      mb.on('databaseloaded', function(ev) {
                          console.info('MBTiles DB loaded', ev);
                      });
                      mb.on('databaseerror', function(ev) {
                          console.info('MBTiles DB error', ev);
                      });
                    </script>
                  </body>
                  </html>
                  

                  這篇關于顯示離線 OSM 映射文件.建議:一個帶有 Js.library 的 MB Tiles 文件的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  Check if a polygon point is inside another in leaflet(檢查一個多邊形點是否在傳單中的另一個內部)
                  Changing leaflet markercluster icon color, inheriting the rest of the default CSS properties(更改傳單標記群集圖標顏色,繼承其余默認 CSS 屬性)
                  Trigger click on leaflet marker(觸發點擊傳單標記)
                  How can I change the default loading tile color in LeafletJS?(如何更改 LeafletJS 中的默認加載磁貼顏色?)
                  Add external geojson to leaflet layer(將外部geojson添加到傳單層)
                  Adding Leaflet layer control to sidebar(將 Leaflet 圖層控件添加到側邊欄)

                    <legend id='JA5YK'><style id='JA5YK'><dir id='JA5YK'><q id='JA5YK'></q></dir></style></legend>
                    <tfoot id='JA5YK'></tfoot>

                        <tbody id='JA5YK'></tbody>
                        <bdo id='JA5YK'></bdo><ul id='JA5YK'></ul>

                        1. <small id='JA5YK'></small><noframes id='JA5YK'>

                            <i id='JA5YK'><tr id='JA5YK'><dt id='JA5YK'><q id='JA5YK'><span id='JA5YK'><b id='JA5YK'><form id='JA5YK'><ins id='JA5YK'></ins><ul id='JA5YK'></ul><sub id='JA5YK'></sub></form><legend id='JA5YK'></legend><bdo id='JA5YK'><pre id='JA5YK'><center id='JA5YK'></center></pre></bdo></b><th id='JA5YK'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='JA5YK'><tfoot id='JA5YK'></tfoot><dl id='JA5YK'><fieldset id='JA5YK'></fieldset></dl></div>
                            主站蜘蛛池模板: 一区二区亚洲 | 亚洲欧美视频 | 自拍偷拍第一页 | 一级黄色毛片a | 九九热精品免费 | 久久婷婷麻豆国产91天堂 | 日本在线你懂的 | 99精品在线观看 | 日韩精品在线播放 | 久久久久久久久99精品 | 污免费网站 | 九九亚洲精品 | 国产精品久久久 | 久久福利电影 | 亚洲国产一区二区三区 | 日韩一区二区三区视频在线播放 | 午夜视频免费在线观看 | 成人av免费在线观看 | 亚洲成人在线免费 | 盗摄精品av一区二区三区 | 免费在线性爱视频 | 日韩福利一区 | 国产欧美精品一区二区 | 国产一区二区三区在线 | 国产一级片一区二区 | 国产视频在线一区二区 | 中文字幕一区在线 | 激情久久网 | 国产一区二区三区 | 国产成人亚洲精品自产在线 | 国产亚洲网站 | 国产精品美女 | 成人中文字幕在线 | 中文字幕在线观看视频一区 | 精品国产网 | 成人片免费看 | 亚洲一区欧美一区 | 久久精品久久久 | 九九热这里 | 一片毛片 | 午夜影院毛片 |