public void TestWHCoord() { double x; double y; Utilities.CoordinateTransform.BD09ToGCJ02(39.915052, 116.403954, out y, out x); Utilities.CoordinateTransform.GCJ02ToWGS84Exact(y, x, out y, out x); //Utilities.CoordinateTransform.WebMercatorToWGS84(2646173.4822,12616007.955, out y, out x); Utilities.CoordinateTransform.WebMercatorToWGS84(2651829.8223, 12621664.2956, out y, out x); Utilities.CoordinateTransform.WGS84ToGCJ02(y, x, out y, out x); Utilities.CoordinateTransform.BD09ToGCJ02(y, x, out y, out x); Utilities.CoordinateTransform.BDO9_LL2MC(y, x, out x, out y); TransverseMercatorHelper.XYToBL_BJ54(33217.091, 49377.203, out x, out y, 121.0, 29195.5, -3401413.0); TransverseMercatorHelper.BLToLocal2000(113.259036, 23.128803, 440100, out x, out y); TransverseMercatorHelper.BLToLocal2000(113.3193437, 23.1450084, 440100, out x, out y); BLToWH54(114.30, 30.60, out x, out y); MapLatLonToXY(30.06, 114.30, out x, out y); double lat; double lon; MapXYToLatLon(x, y, out lon, out lat); WH2000ToBL(795761.0955, 380570.6057, out lon, out lat); WH54ToBL(461574.705, 3271333.382, out lon, out lat); MapXYToLatLon(461574.705, 3271333.382, out lat, out lon); }
public override MapPoint LatLonToXY(double lat, double lon) { if (Srid > 100000) { TransverseMercatorHelper.BLToLocal2000(lon, lat, Srid, out double x, out double y); return(new MapPoint() { X = x, Y = y }); } throw new NotSupportedException(); }