Geometry rotate 2d(几何二维旋转(Geometry rotate 2d))¶
Supported in: Streaming
Applies a two dimensional clockwise rotation centered at the provided GeoPoint to the supplied geometry. This rotation occurs in the provided coordinate reference system and is then projected back to WGS84.
Expression categories: Geospatial
Declared arguments¶
- Angle in degrees: The angle in degrees of clockwise rotation.
Literal\ - Centre GeoPoint: The centre GeoPoint about which the rotation occurs. Assumed to be in WGS84.
Expression\ - Geometry column: The geometries on which the rotation is applied.
Expression\ - Projected coordinate system: Coordinate system identifier formatted as "authority:id". For example, UTM zone 18N could be identified by EPSG:32618. Geometries will be projected to the source coordinate system, have a rotation applied, then projected back to WGS84.
Literal\
Output type: Geometry
Examples¶
Example 1: Base case¶
Argument values:
- Angle in degrees: 90.0
- Centre GeoPoint:
geoPoint - Geometry column:
geometry - Projected coordinate system: EPSG:4326
| geometry | geoPoint | Output |
|---|---|---|
| {"type":"Point","coordinates":[1.0, 0.0]} | { latitude -> 0.0, longitude -> 0.0, } |
{"type":"Point","coordinates":[6.123233995736766E-17, -1.0]} |
Example 2: Base case¶
Argument values:
- Angle in degrees: 270.0
- Centre GeoPoint:
geoPoint - Geometry column:
geometry - Projected coordinate system: EPSG:32618
| geometry | geoPoint | Output |
|---|---|---|
| {"type":"Point","coordinates":[-77.0, 20.0]} | { latitude -> 22.0, longitude -> -76.0, } |
{"type":"Point","coordinates":[-73.8719606865239, 21.041418391118174]} |
Example 3: Base case¶
Argument values:
- Angle in degrees: 180.0
- Centre GeoPoint:
geoPoint - Geometry column:
geometry - Projected coordinate system: EPSG:4326
| geometry | geoPoint | Output |
|---|---|---|
| {"type":"LineString","coordinates":[[0.0, 0.0], [1.0, 0.0]]} | { latitude -> 1.0, longitude -> 1.0, } |
{"type":"LineString","coordinates":[[2.0, 2.0], [0.9999999999999999, 2.0]]} |
Example 4: Null case¶
Argument values:
- Angle in degrees: 90.0
- Centre GeoPoint:
geoPoint - Geometry column:
geometry - Projected coordinate system: EPSG:4326
| geometry | geoPoint | Output |
|---|---|---|
| null | null | null |
中文翻译¶
几何二维旋转(Geometry rotate 2d)¶
支持:流式处理(Streaming)
对提供的几何图形应用以指定地理点(GeoPoint)为中心的顺时针二维旋转。该旋转在提供的坐标参考系中执行,然后投影回WGS84坐标系。
表达式类别: 地理空间(Geospatial)
声明的参数¶
- 旋转角度(度): 顺时针旋转的角度,单位为度。
字面量\ - 中心地理点(Centre GeoPoint): 旋转所围绕的中心地理点。假定采用WGS84坐标系。
表达式\ - 几何列(Geometry column): 应用旋转的几何图形。
表达式\ - 投影坐标系(Projected coordinate system): 格式为"authority:id"的坐标系标识符。例如,UTM 18N区可由EPSG:32618标识。几何图形将被投影到源坐标系,应用旋转,然后投影回WGS84坐标系。
字面量\
输出类型: Geometry
示例¶
示例1:基本情况¶
参数值:
- 旋转角度(度): 90.0
- 中心地理点:
geoPoint - 几何列:
geometry - 投影坐标系: EPSG:4326
| geometry | geoPoint | 输出 |
|---|---|---|
| {"type":"Point","coordinates":[1.0, 0.0]} | { latitude -> 0.0, longitude -> 0.0, } |
{"type":"Point","coordinates":[6.123233995736766E-17, -1.0]} |
示例2:基本情况¶
参数值:
- 旋转角度(度): 270.0
- 中心地理点:
geoPoint - 几何列:
geometry - 投影坐标系: EPSG:32618
| geometry | geoPoint | 输出 |
|---|---|---|
| {"type":"Point","coordinates":[-77.0, 20.0]} | { latitude -> 22.0, longitude -> -76.0, } |
{"type":"Point","coordinates":[-73.8719606865239, 21.041418391118174]} |
示例3:基本情况¶
参数值:
- 旋转角度(度): 180.0
- 中心地理点:
geoPoint - 几何列:
geometry - 投影坐标系: EPSG:4326
| geometry | geoPoint | 输出 |
|---|---|---|
| {"type":"LineString","coordinates":[[0.0, 0.0], [1.0, 0.0]]} | { latitude -> 1.0, longitude -> 1.0, } |
{"type":"LineString","coordinates":[[2.0, 2.0], [0.9999999999999999, 2.0]]} |
示例4:空值情况¶
参数值:
- 旋转角度(度): 90.0
- 中心地理点:
geoPoint - 几何列:
geometry - 投影坐标系: EPSG:4326
| geometry | geoPoint | 输出 |
|---|---|---|
| null | null | null |