pbootcms网站模板|日韩1区2区|织梦模板||网站源码|日韩1区2区|jquery建站特效-html5模板网

  • <tfoot id='HBiGR'></tfoot>

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

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

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

        使用傳單獲取 geojson 大陸/國家/州的中心

        Get center of geojson Continent/Country/State with leaflet(使用傳單獲取 geojson 大陸/國家/州的中心)
      2. <i id='FOZNl'><tr id='FOZNl'><dt id='FOZNl'><q id='FOZNl'><span id='FOZNl'><b id='FOZNl'><form id='FOZNl'><ins id='FOZNl'></ins><ul id='FOZNl'></ul><sub id='FOZNl'></sub></form><legend id='FOZNl'></legend><bdo id='FOZNl'><pre id='FOZNl'><center id='FOZNl'></center></pre></bdo></b><th id='FOZNl'></th></span></q></dt></tr></i><div class="5bpnfvn" id='FOZNl'><tfoot id='FOZNl'></tfoot><dl id='FOZNl'><fieldset id='FOZNl'></fieldset></dl></div>
        • <legend id='FOZNl'><style id='FOZNl'><dir id='FOZNl'><q id='FOZNl'></q></dir></style></legend>

                <tbody id='FOZNl'></tbody>
              <tfoot id='FOZNl'></tfoot>
              • <bdo id='FOZNl'></bdo><ul id='FOZNl'></ul>
                • <small id='FOZNl'></small><noframes id='FOZNl'>

                • 本文介紹了使用傳單獲取 geojson 大陸/國家/州的中心的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  有沒有辦法為由多個多邊形對象組成的國家/大陸(例如美國、加拿大,除了主要陸地部分還有一個島嶼)找到一個中心?我試圖使用傳單的 Layer.getCenter() 甚至 Layer.getBounds().getCenter(),但這些方法肯定不適用于這類國家并返回no-go"結果.

                  可以通過以下鏈接(傳單游樂場)查看示例.只需滾動并單擊美國或加拿大,然后查看 circleMarker 將出現的位置.然后嘗試點擊較小的實體,例如美國南部的一些島嶼,他們會將此標記精確地放置在它們的中心:


                  (來源:postgis.net)

                  (圖 1.根據 PostGIS 的 ST_Centroid 文檔的多邊形質心)

                  所以我猜你真正想問的是:

                  <塊引用>

                  給定一個多邊形或多多邊形,我如何計算一個中心(或類似中心的點),它保證在多邊形內并在視覺上看起來在它的中心,以便使用 Leaflet 將符號器添加到該點?

                  為此,答案是 極難訪問" 由 實現polylabel:?多邊形輪廓最遠的內部點?.

                  Is there a way of finding a center for countries/continents which consist of more than one polygon object(ex. USA, Canada, which have an islands besides main land part)? I was trying to use leaflet's Layer.getCenter() or even Layer.getBounds().getCenter(), but those methods certainly don't work for this type of countries and return a "no-go" results.

                  Example can be seen by the following link (leaflet playground). Just scroll and click on US or Canada and see where circleMarker will appear. Then try clicking on smaller entities, like some islands on south of US, they shall place this marker precisely on center of'em:

                  http://playground-leaflet.rhcloud.com/voyi/1/edit?html,output

                  解決方案

                  Leaflet can only calculate the center of the bounding box of a feature. With a bit of help from other libraries (such as Turf.js) you can calculate the centroid of the polygon or (multipolygon).

                  In any case, you are getting confused because sometimes the centroid is not within the polygon (or multipolygon):


                  (source: postgis.net)

                  (Figure 1. Centroid of a polygon as per PostGIS's ST_Centroid documentation)

                  So I guess that what you really wanted to ask is:

                  Given a polygon or multipolygon, how can I calculate a center (or center-like point) which is guaranteed to be within the polygon and looks visually in the center of it, in order to add symbolizers to that point with Leaflet?

                  And for that, the answer is "pole of inaccessibility" as implemented by polylabel: ?the most distant internal point from the polygon outline?.

                  這篇關于使用傳單獲取 geojson 大陸/國家/州的中心的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持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 圖層控件添加到側邊欄)

                        <tbody id='H1MWx'></tbody>
                    • <tfoot id='H1MWx'></tfoot>
                        <bdo id='H1MWx'></bdo><ul id='H1MWx'></ul>

                          <legend id='H1MWx'><style id='H1MWx'><dir id='H1MWx'><q id='H1MWx'></q></dir></style></legend>

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

                            <i id='H1MWx'><tr id='H1MWx'><dt id='H1MWx'><q id='H1MWx'><span id='H1MWx'><b id='H1MWx'><form id='H1MWx'><ins id='H1MWx'></ins><ul id='H1MWx'></ul><sub id='H1MWx'></sub></form><legend id='H1MWx'></legend><bdo id='H1MWx'><pre id='H1MWx'><center id='H1MWx'></center></pre></bdo></b><th id='H1MWx'></th></span></q></dt></tr></i><div class="f5tbbxh" id='H1MWx'><tfoot id='H1MWx'></tfoot><dl id='H1MWx'><fieldset id='H1MWx'></fieldset></dl></div>
                          • 主站蜘蛛池模板: 氧化铁红厂家-淄博宗昂化工| 镀锌方管,无缝方管,伸缩套管,方矩管_山东重鑫致胜金属制品有限公司 | PC构件-PC预制构件-构件设计-建筑预制构件-PC构件厂-锦萧新材料科技(浙江)股份有限公司 | 宁夏活性炭_防护活性炭_催化剂载体炭-宁夏恒辉活性炭有限公司 | 上海网站建设-上海网站制作-上海网站设计-上海做网站公司-咏熠软件 | 贝朗斯动力商城(BRCPOWER.COM) - 买叉车蓄电池上贝朗斯商城,价格更超值,品质有保障! | 一技任务网_有一技之长,就来技术任务网 | 电梯乘运质量测试仪_电梯安全评估测试仪-武汉懿之刻 | 福州时代广告制作装饰有限公司-福州广告公司广告牌制作,福州展厅文化墙广告设计, | 磁力加热搅拌器-多工位|大功率|数显恒温磁力搅拌器-司乐仪器官网 | 山东太阳能路灯厂家-庭院灯生产厂家-济南晟启灯饰有限公司 | 耐酸泵,耐酸泵厂家-淄博华舜耐腐蚀真空泵 | 北京中创汇安科贸有限公司| 螺钉式热电偶_便携式温度传感器_压簧式热电偶|无锡联泰仪表有限公司|首页 | 轴流风机-鼓风机-离心风机-散热风扇-罩极电机,生产厂家-首肯电子 | 托利多电子平台秤-高精度接线盒-托利多高精度电子秤|百科 | 红酒招商加盟-葡萄酒加盟-进口红酒代理-青岛枞木酒业有限公司 | HYDAC过滤器,HYDAC滤芯,现货ATOS油泵,ATOS比例阀-东莞市广联自动化科技有限公司 | 澳门精准正版免费大全,2025新澳门全年免费,新澳天天开奖免费资料大全最新,新澳2025今晚开奖资料,新澳马今天最快最新图库-首页-东莞市傲马网络科技有限公司 | 水热合成反应釜-防爆高压消解罐-西安常仪仪器设备有限公司 | 黑龙江「京科脑康」医院-哈尔滨失眠医院_哈尔滨治疗抑郁症医院_哈尔滨精神心理医院 | 纯化水设备-纯水设备-超纯水设备-[大鹏水处理]纯水设备一站式服务商-东莞市大鹏水处理科技有限公司 | 短信营销平台_短信群发平台_106短信发送平台-河南路尚 | 塑胶跑道_学校塑胶跑道_塑胶球场_运动场材料厂家_中国塑胶跑道十大生产厂家_混合型塑胶跑道_透气型塑胶跑道-广东绿晨体育设施有限公司 | 齿轮减速机电机一体机_齿轮减速箱加电机一体化-德国BOSERL蜗轮蜗杆减速机电机生产厂家 | 别墅图纸超市|别墅设计图纸|农村房屋设计图|农村自建房|别墅设计图纸及效果图大全 | 丝印油墨_水性油墨_环保油墨油漆厂家_37国际化工 | 天津试验仪器-电液伺服万能材料试验机,恒温恒湿标准养护箱,水泥恒应力压力试验机-天津鑫高伟业科技有限公司 | 布袋除尘器|除尘器设备|除尘布袋|除尘设备_诺和环保设备 | 合肥汽车充电桩_安徽充电桩_电动交流充电桩厂家_安徽科帝新能源科技有限公司 | 回转炉,外热式回转窑,回转窑炉-淄博圣元窑炉工程有限公司 | 专业深孔加工_东莞深孔钻加工_东莞深孔钻_东莞深孔加工_模具深孔钻加工厂-东莞市超耀实业有限公司 | 玉米深加工机械,玉米加工设备,玉米加工机械等玉米深加工设备制造商-河南成立粮油机械有限公司 | 武汉不干胶印刷_标签设计印刷_不干胶标签印刷厂 - 武汉不干胶标签印刷厂家 | 鼓风干燥箱_真空烘箱_高温干燥箱_恒温培养箱-上海笃特科学仪器 | 上海平衡机-单面卧式动平衡机-万向节动平衡机-圈带动平衡机厂家-上海申岢动平衡机制造有限公司 | 不锈钢酒柜|恒温酒柜|酒柜定制|酒窖定制-上海啸瑞实业有限公司 | 福建省教师资格证-福建教师资格证考试网 | 铝箔袋,铝箔袋厂家,东莞铝箔袋,防静电铝箔袋,防静电屏蔽袋,防静电真空袋,真空袋-东莞铭晋让您的产品与众不同 | 丽陂特官网_手机信号屏蔽器_Wifi信号干扰器厂家_学校考场工厂会议室屏蔽仪 | 即用型透析袋,透析袋夹子,药敏纸片,L型涂布棒-上海桥星贸易有限公司 |