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

    • <bdo id='KQ6EO'></bdo><ul id='KQ6EO'></ul>

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

        <small id='KQ6EO'></small><noframes id='KQ6EO'>

      1. <legend id='KQ6EO'><style id='KQ6EO'><dir id='KQ6EO'><q id='KQ6EO'></q></dir></style></legend>
        <tfoot id='KQ6EO'></tfoot>

        如何找到最近的標記leaflet.js

        How to find closest marker leaflet.js(如何找到最近的標記leaflet.js)

          <bdo id='eA1oO'></bdo><ul id='eA1oO'></ul>
          <legend id='eA1oO'><style id='eA1oO'><dir id='eA1oO'><q id='eA1oO'></q></dir></style></legend>

          <small id='eA1oO'></small><noframes id='eA1oO'>

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

                1. <tfoot id='eA1oO'></tfoot>

                    <tbody id='eA1oO'></tbody>
                  本文介紹了如何找到最近的標記leaflet.js的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我想知道是否真的有某種方法可以使用 Leaflet.js 在我的位置附近找到標記.我想到的第一個想法是存儲我的位置的 lat 和 lng,然后遍歷一組 lat 和 lng 標記,將它們放在一個數(shù)組中,然后對該數(shù)組進行排序.我不確定這是否是一個不錯的選擇,因為如果您在地圖上有一百萬個標記需要一段時間.

                  I was wondering if there is actually some way to find markers near my position using leaflet.js. The first think to come to my head is to store lat and lng of my position and then iterate over an array of lat and lng markers placing them in an array an then sort that array. I am not sure if this is a good option because if you have a million markers in the map is going to take a while.

                  偽代碼

                  var myLatLng = [34,56];
                  var markers = [[20,30],[10,20],[12,-100],[54,90],[-10, -20],[20,20]];
                  var closests = [];
                  function findNearestMarker (myPosition, nearestMarkers){
                   for(var i = 0; i < nearestMarkers.length){
                       if((nearestMarkers[i][0] - myPosition[0]) < 100 && (nearestMarkers[i][1] - myPosition[1]) < 100 ){
                           closests.push(nearestMarkers[i])
                       }
                   }
                  }
                  

                  我實際上是從地圖開始,不知道這么多方法,我也想在這個項目中使用開放的街道地圖,但是,如果有人知道并使用谷歌地圖或其他服務,我將受到歡迎.

                  I am actually starting with maps and dont know so many approaches, I will also like to use open street maps for this project, but, if someone know and aproach using google maps or another services it will be welcomed.

                  推薦答案

                  試試leaflet-knn,它進行最近鄰查找:給定一個點和一堆其他點,它會找到最近的鄰居(正如它在錫上所說的那樣)

                  Try leaflet-knn, which does nearest-neighbor lookups: given a point and a bunch of other points, it finds the nearest neighbors (as it says on the tin)

                  這篇關(guān)于如何找到最近的標記leaflet.js的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

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

                  相關(guān)文檔推薦

                  Check if a polygon point is inside another in leaflet(檢查一個多邊形點是否在傳單中的另一個內(nèi)部)
                  Changing leaflet markercluster icon color, inheriting the rest of the default CSS properties(更改傳單標記群集圖標顏色,繼承其余默認 CSS 屬性)
                  Trigger click on leaflet marker(觸發(fā)點擊傳單標記)
                  How can I change the default loading tile color in LeafletJS?(如何更改 LeafletJS 中的默認加載磁貼顏色?)
                  Adding Leaflet layer control to sidebar(將 Leaflet 圖層控件添加到側(cè)邊欄)
                  Leaflet - get latitude and longitude of a marker inside a pop-up(Leaflet - 在彈出窗口中獲取標記的緯度和經(jīng)度)
                  <legend id='LFpyO'><style id='LFpyO'><dir id='LFpyO'><q id='LFpyO'></q></dir></style></legend>
                    <tbody id='LFpyO'></tbody>

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

                            <tfoot id='LFpyO'></tfoot>
                            主站蜘蛛池模板: 午夜影院在线免费观看 | 天天草天天干 | 午夜性福利| 亚洲精品自拍视频 | 一区二区高清 | 亚洲欧洲av| 狠狠做深爱婷婷久久综合一区 | 欧美视频精品 | 欧美一级精品 | 欧美日韩国产在线观看 | www.久久久久 | 国产色视频一区二区三区qq号 | 四虎色播 | 97在线播放 | 天海翼在线视频 | 中文字幕第2页 | 精品免费国产 | 狠狠操天天操 | 国产精品久久网 | 久久久久国产精品夜夜夜夜夜 | 久久综合99 | 91麻豆精品国产91久久久久久 | 欧美在线一级 | 国产精品一区二区三区不卡 | 黄色一级免费 | 一区视频在线 | 青草av在线| 精品亚洲国产成人av制服丝袜 | 伊人干综合 | 成人三级在线观看 | 久久精品av | 秋霞av在线 | 中文字幕在线免费观看 | 在线视频成人 | 视频一区在线播放 | 蜜桃一区二区 | 免费视频一区 | 亚洲视频在线观看 | 五月天视频 | 久草福利在线观看 | 人人看人人干 |