GeoJSON
GeoJson简介
Link
线上 Demo:https://geojson.io/#map=2/0/20

Wiki Notes
GeoJSON是一种开放的标准格式,用于表示简单的地理特征沿着非空间属性。它基于JSON格式。
Types
Picture
Code
点

{
"type": "Point",
"coordinates": [30.0, 10.0]
}线

{
"type": "LineString",
"coordinates": [
[30.0, 10.0],
[10.0, 30.0],
[40.0, 40.0]
]
}多边形

{
"type": "Polygon",
"coordinates": [
[
[30.0, 10.0],
[40.0, 40.0],
[20.0, 40.0],
[10.0, 20.0],
[30.0, 10.0]
]
]
}多边形

{
"type": "Polygon",
"coordinates": [
[
[35.0, 10.0],
[45.0, 45.0],
[15.0, 40.0],
[10.0, 20.0],
[35.0, 10.0]
],
[
[20.0, 30.0],
[35.0, 35.0],
[30.0, 20.0],
[20.0, 30.0]
]
]
}多点

{
"type": "MultiPoint",
"coordinates": [
[10.0, 40.0],
[40.0, 30.0],
[20.0, 20.0],
[30.0, 10.0]
]
}多线

{
"type": "MultiLineString",
"coordinates": [
[
[10.0, 10.0],
[20.0, 20.0],
[10.0, 40.0]
],
[
[40.0, 40.0],
[30.0, 30.0],
[40.0, 20.0],
[30.0, 10.0]
]
]
}多体

{
"type": "MultiPolygon",
"coordinates": [
[
[
[30.0, 20.0],
[45.0, 40.0],
[10.0, 40.0],
[30.0, 20.0]
]
],
[
[
[15.0, 5.0],
[40.0, 10.0],
[10.0, 20.0],
[5.0, 10.0],
[15.0, 5.0]
]
]
]
}多体

{
"type": "MultiPolygon",
"coordinates": [
[
[
[40.0, 40.0],
[20.0, 45.0],
[45.0, 30.0],
[40.0, 40.0]
]
],
[
[
[20.0, 35.0],
[10.0, 30.0],
[10.0, 10.0],
[30.0, 5.0],
[45.0, 20.0],
[20.0, 35.0]
],
[
[30.0, 20.0],
[20.0, 15.0],
[20.0, 25.0],
[30.0, 20.0]
]
]
]
}集合

{
"type": "GeometryCollection",
"geometries": [
{
"type": "Point",
"coordinates": [40.0, 10.0]
},
{
"type": "LineString",
"coordinates": [
[10.0, 10.0],
[20.0, 20.0],
[10.0, 40.0]
]
},
{
"type": "Polygon",
"coordinates": [
[
[40.0, 40.0],
[20.0, 45.0],
[45.0, 30.0],
[40.0, 40.0]
]
]
}
]
}最后更新于
这有帮助吗?