gisarmory / leaflet.internetmapcorrection Goto Github PK
View Code? Open in Web Editor NEW互联网地图纠偏
互联网地图纠偏
OSM类地图使用WGS84坐标系统,高德等使用GCJ02,百度使用BD09,那请问为什么高德等GCJ02可以通过坐标转换后直接使用默认的CRS,而百度地图需要设置新的CRS (crs: L.CRS.Baidu)?按照我的理解,我们知道了WGS84 - GCJ02 - BD09之间的变换,那么百度地图应该也可以转换到WGS84,而不需要设置单独的CRS?
这个问题源于我想把百度地图、高德地图、OSM类地图放在一个地图中,发现Leaflet本身不支持不同CRS的图层,所以百度地图没法放进去。
请问能否自行修改以下两个插件后添加新图层?
新增Map: {
Normal: {
Map: '//webrd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}'
},
Satellite: {
Map: '//webst0{s}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}',
Annotion: '//webst0{s}.is.autonavi.com/appmaptile?style=8&x={x}&y={y}&z={z}'
},
Subdomains: ["1", "2", "3", "4"]
},
case "Geoq":case "GaoDe":case "Google":case "新增Map":c="gcj02"
“leaflet.mapCorrection.js:145 Uncaught TypeError: Cannot read property 'include' of undefined
at leaflet.mapCorrection.js:145”
纠偏后,使用了一个测量的插件,发现测量的文本标注出现偏离,怀疑是纠偏插件的问题。
测量插件用到了_map.latLngToLayerPoint() 这个函数,会不会纠偏插件也会影响到这个函数。
类似函数还有一个 _map.layerPointToLatLng()
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.