|
|
@ -1,3 +1,9 @@ |
|
|
|
|
|
|
|
var pi = 3.1415926535897932384626; |
|
|
|
|
|
|
|
var a = 6378245.0; |
|
|
|
|
|
|
|
var ee = 0.00669342162296594323; |
|
|
|
|
|
|
|
var x_pi = (pi * 3000.0) / 180.0; |
|
|
|
|
|
|
|
var R = 6378137; |
|
|
|
|
|
|
|
|
|
|
|
export const bd09_To_gps84 = function (lng, lat) { |
|
|
|
export const bd09_To_gps84 = function (lng, lat) { |
|
|
|
var gcj02 = bd09_To_gcj02(lng, lat); |
|
|
|
var gcj02 = bd09_To_gcj02(lng, lat); |
|
|
|
var map84 = gcj02_To_gps84(gcj02.lng, gcj02.lat); |
|
|
|
var map84 = gcj02_To_gps84(gcj02.lng, gcj02.lat); |
|
|
@ -65,12 +71,6 @@ export const bd09_To_gcj02 = function (bd_lng, bd_lat) { |
|
|
|
return newCoord; |
|
|
|
return newCoord; |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
var pi = 3.1415926535897932384626; |
|
|
|
|
|
|
|
var a = 6378245.0; |
|
|
|
|
|
|
|
var ee = 0.00669342162296594323; |
|
|
|
|
|
|
|
var x_pi = (pi * 3000.0) / 180.0; |
|
|
|
|
|
|
|
var R = 6378137; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function transform(lng, lat) { |
|
|
|
function transform(lng, lat) { |
|
|
|
var dLat = transformLat(lng - 105.0, lat - 35.0); |
|
|
|
var dLat = transformLat(lng - 105.0, lat - 35.0); |
|
|
|
var dLng = transformLng(lng - 105.0, lat - 35.0); |
|
|
|
var dLng = transformLng(lng - 105.0, lat - 35.0); |
|
|
|