ArcGis Rest API - 如何从 MapServer 获取栅格图层?
ArcGis Rest API - How to get raster layer from MapServer?
我正在尝试通过 ArcGIS REST 从澳大利亚政府获取栅格图层(5 米数字高程模型 (DEM))API
url: https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/
我可以对边界层和足迹层执行查询并获得良好结果
边界查询:
"https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/1/query?where=&text=&objectIds=&time=&geometry=xmin:133.226100657682, ymin:-23.6165145646468, xmax:133.235899342318, ymax :-23.6074854353532&geometryType=esriGeometryEnvelope&inSR=4283&spatialRel=esriSpatialRelEnvelopeIntersects&relationParam=&outFields=&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&gdbVersion=&returnDistinctValues=false&f=json"
响应(在 R 中绘制):
R plot through jsonlite response
足迹查询:
"https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/2/query?where=&text=&objectIds=&time=&geometry=xmin:133.226100657682, ymin:-23.6165145646468, xmax:133.235899342318, ymax :-23.6074854353532&geometryType=esriGeometryEnvelope&inSR=4283&spatialRel=esriSpatialRelEnvelopeIntersects&relationParam=&outFields=&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&gdbVersion=&returnDistinctValues=false&f=json"
回复:
jsonlite response in R
我从哪里得到了我正在寻找的 TIF 文件的名称,但是我对栅格图层的所有查询:https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/3
没有给我任何结果
我也尝试了 rcran 包“arcpullr”,但没有结果
有什么帮助吗?
library(arcpullr)
library(sf)
library(jsonlite)
loc_lng <- 133.231
loc_lat <- -23.612
study_area <- 1000
bbox_area <- osmar::center_bbox(loc_lng, loc_lat, study_area, study_area)
loc_bbox_pol <- tmaptools::bb_poly(bbox_area)
loc_bbox_pol <- sf::st_as_sf(loc_bbox_pol)
sf::st_crs(loc_bbox_pol) = 4326
loc_bbox_pol <- sf::st_transform(loc_bbox_pol, 4283)
DEM_general <- arcpullr::get_layer_by_poly("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/0/", loc_bbox_pol, sp_rel = "esriSpatialRelIndexIntersects")
DEM_Boundary <- arcpullr::get_layer_by_poly("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/1/", loc_bbox_pol, sp_rel = "esriSpatialRelIndexIntersects")
DEM_Info <- arcpullr::get_layer_by_poly("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/2/", loc_bbox_pol, sp_rel = "esriSpatialRelIndexIntersects")
arcpullr::get_service_type("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/3/")
我正在尝试通过 ArcGIS REST 从澳大利亚政府获取栅格图层(5 米数字高程模型 (DEM))API
url: https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/
我可以对边界层和足迹层执行查询并获得良好结果
边界查询:
"https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/1/query?where=&text=&objectIds=&time=&geometry=xmin:133.226100657682, ymin:-23.6165145646468, xmax:133.235899342318, ymax :-23.6074854353532&geometryType=esriGeometryEnvelope&inSR=4283&spatialRel=esriSpatialRelEnvelopeIntersects&relationParam=&outFields=&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&gdbVersion=&returnDistinctValues=false&f=json"
响应(在 R 中绘制):
R plot through jsonlite response
足迹查询:
"https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/2/query?where=&text=&objectIds=&time=&geometry=xmin:133.226100657682, ymin:-23.6165145646468, xmax:133.235899342318, ymax :-23.6074854353532&geometryType=esriGeometryEnvelope&inSR=4283&spatialRel=esriSpatialRelEnvelopeIntersects&relationParam=&outFields=&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&gdbVersion=&returnDistinctValues=false&f=json"
回复:
jsonlite response in R
我从哪里得到了我正在寻找的 TIF 文件的名称,但是我对栅格图层的所有查询:https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/3 没有给我任何结果
我也尝试了 rcran 包“arcpullr”,但没有结果
有什么帮助吗?
library(arcpullr)
library(sf)
library(jsonlite)
loc_lng <- 133.231
loc_lat <- -23.612
study_area <- 1000
bbox_area <- osmar::center_bbox(loc_lng, loc_lat, study_area, study_area)
loc_bbox_pol <- tmaptools::bb_poly(bbox_area)
loc_bbox_pol <- sf::st_as_sf(loc_bbox_pol)
sf::st_crs(loc_bbox_pol) = 4326
loc_bbox_pol <- sf::st_transform(loc_bbox_pol, 4283)
DEM_general <- arcpullr::get_layer_by_poly("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/0/", loc_bbox_pol, sp_rel = "esriSpatialRelIndexIntersects")
DEM_Boundary <- arcpullr::get_layer_by_poly("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/1/", loc_bbox_pol, sp_rel = "esriSpatialRelIndexIntersects")
DEM_Info <- arcpullr::get_layer_by_poly("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/2/", loc_bbox_pol, sp_rel = "esriSpatialRelIndexIntersects")
arcpullr::get_service_type("https://services.ga.gov.au/site_9/rest/services/DEM_LiDAR_5m/MapServer/3/")