gpt4 book ai didi

mapbox - 将 ArcGIS Server REST 服务 API 消费到 MapBox GL API 中

转载 作者:行者123 更新时间:2023-12-02 04:38:31 25 4
gpt4 key购买 nike

我可以在 MapBox GL API 中使用 ArcGIS Server REST 服务 API 吗?请任何人告诉我是否可以将 ArcGIS Rest 服务消费到 MapBox GIS 中。谢谢!!

最佳答案

您可以使用 GeoJSON 作为要素服务的中间格式。 ArcGIS Server 支持 GeoJSON since version 10.4和 MapBox GL API 支持 reading GeoJSON .

这是一个片段:

map.on('load', function () {
// Add a layer showing the city parks
map.addLayer({
'id': 'parks-layer',
'type': 'fill',
'source': {
'type': 'geojson',
'data': 'https://services.arcgis.com/V6ZHFr6zdgNZuVG0/ArcGIS/rest/services/City_of_Redlands_Parks/FeatureServer/0/query?where=1%3D1&outSR=4326&f=pgeojson'
},
'paint': {
'fill-color': 'rgba(200, 100, 240, 0.3)',
'fill-outline-color': 'rgba(200, 100, 240, 1)'
}
});
});

关于mapbox - 将 ArcGIS Server REST 服务 API 消费到 MapBox GL API 中,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43798531/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com