pointconvert

点坐标的转换

Methods

(static) bd2gcj(bd_lon, bd_lat) → {Array.<Number>}

百度坐标系 (BD-09) 与 国测局坐标系 (GCJ-02)的转换
即 百度 转 谷歌、高德

Parameters:
Name Type Description
bd_lon
bd_lat
Returns:
Type
Array.<Number>

(static) bd2wgs(arrdata) → {Array.<Number>}

百度经纬度坐标 转 标准WGS84坐标

Parameters:
Name Type Description
arrdata Array

百度经纬度数组

Returns:
Type
Array.<Number>

(static) cartesian2lonlat(cartesian) → {Array}

cesium笛卡尔空间坐标 转 经纬度坐标【用于转geojson】

Parameters:
Name Type Description
cartesian cartesian
Returns:
Type
Array

(static) cartesian2mercator(position) → {Array}

cesium笛卡尔空间坐标 转 web mercator投影坐标

Parameters:
Name Type Description
position Cartesian3

点信息

Returns:
Type
Array

(static) cartesians2lonlats(positions) → {Array}

数组,cesium笛卡尔空间坐标 转 经纬度坐标【用于转geojson】

Parameters:
Name Type Description
positions Array

一组点组

Returns:
Type
Array

(static) cartesians2mercators(arr) → {Array}

cesium笛卡尔空间坐标 转 web mercator投影坐标

Parameters:
Name Type Description
arr Array

Cartesian3 数组

Returns:
Type
Array

(static) gcj2bd(lng, lat) → {Array.<Number>}

国测局坐标系 (GCJ-02) 与百度坐标系 (BD-09) 的转换
即谷歌、高德 转 百度

Parameters:
Name Type Description
lng
lat
Returns:
Type
Array.<Number>

(static) gcj2wgs(lng, lat) → {Array.<Number>}

GCJ02 转换为 WGS84

Parameters:
Name Type Description
lng
lat
Returns:
Type
Array.<Number>

(static) jwd2mct(arrdata) → {Array}

经纬度转Web墨卡托

Parameters:
Name Type Description
arrdata Array

数组

Returns:
Type
Array

(static) lonlat2cartesian(coord, defHeight) → {Cesium.Cartesian3}

经纬度坐标 转 cesium笛卡尔空间坐标

Parameters:
Name Type Description
coord Array

Cartesian3 数组

defHeight Number

高度信息

Returns:
Type
Cesium.Cartesian3

(static) lonlat2mercator(lnglat) → {Cesium.Cartesian3}

地理坐标 转 投影坐标

Parameters:
Name Type Description
lnglat Array

经纬度

Returns:
Type
Cesium.Cartesian3

(static) lonlats2cartesians(coord, defHeight) → {Array}

经纬度坐标 转 cesium笛卡尔空间坐标

Parameters:
Name Type Description
coord Array

Cartesian3 数组

defHeight Number

高度信息

Returns:
Type
Array

(static) lonlats2mercators(arr) → {Array}

数组,地理坐标 转 投影坐标

Parameters:
Name Type Description
arr Array

地理坐标

Returns:
Type
Array

(static) mct2jwd(arrdata) → {Array}

Web墨卡托转经纬度

Parameters:
Name Type Description
arrdata Array

Web墨卡托

Returns:
Type
Array

(static) mercator2cartesian(point) → {Cesium.Cartesian3}

投影坐标 转 cesium笛卡尔空间坐标

Parameters:
Name Type Description
point Array

投影坐标

Returns:
Type
Cesium.Cartesian3

(static) mercator2lonlat(point) → {Array}

投影坐标 转 地理坐标

Parameters:
Name Type Description
point Object
Returns:
Type
Array

(static) mercators2cartesians(arr) → {Array}

投影坐标 转 cesium笛卡尔空间坐标

Parameters:
Name Type Description
arr Array

投影坐标

Returns:
Type
Array

(static) mercators2lonlats(arr) → {Array}

数组,投影坐标 转 地理坐标

Parameters:
Name Type Description
arr Array

投影坐标

Returns:
Type
Array

(static) wgs2bd(arrdata) → {Array.<Number>}

标准WGS84坐标 转 百度经纬度坐标

Parameters:
Name Type Description
arrdata Array

标准WGS84坐标数组

Returns:
Type
Array.<Number>

(static) wgs2gcj(lng, lat) → {Array.<Number>}

WGS84转GCj02

Parameters:
Name Type Description
lng
lat
Returns:
Type
Array.<Number>

(inner) out_of_china(lng, lat) → {boolean}

判断是否在国内,不在国内则不做偏移

Parameters:
Name Type Description
lng
lat
Returns:
Type
boolean