21.引用proj4js文件
2.定义投影坐标系统
1)国家2000地理坐标系
proj4.defs("EPSG:4490","+proj=longlat +ellps=GRS80 +no_defs");
2)国家2000平面坐标系
proj4.defs("EPSG:4548","+proj=tmerc +lat_0=0 +lon_0=117 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs");
3.实现坐标投影转换(国家2000平面坐标系到国家2000地理坐标系)
var gcs4490 = ol.proj.transform([605906.540647357,2723639.37418766], new ol.proj.Projection({code:'EPSG:4548'}),
new ol.proj.Projection({code:'EPSG:4490'}));
4.epsg proj4格式定义列表
# Xian 1980
<4610> +proj=longlat +a=6378140 +b=6356755.288157528 +no_defs <>
# China Geodetic Coordinate System 2000
<4490> +proj=longlat +ellps=GRS80 +no_defs <>
# WGS 84
<4326> +proj=longlat +datum=WGS84 +no_defs <>
# CGCS2000 / Gauss-Kruger zone 13
<4491> +proj=tmerc +lat_0=0 +lon_0=75 +k=1 +x_0=13500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 14
<4492> +proj=tmerc +lat_0=0 +lon_0=81 +k=1 +x_0=14500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 15
<4493> +proj=tmerc +lat_0=0 +lon_0=87 +k=1 +x_0=15500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 16
<4494> +proj=tmerc +lat_0=0 +lon_0=93 +k=1 +x_0=16500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 17
<4495> +proj=tmerc +lat_0=0 +lon_0=99 +k=1 +x_0=17500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 18
<4496> +proj=tmerc +lat_0=0 +lon_0=105 +k=1 +x_0=18500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 19
<4497> +proj=tmerc +lat_0=0 +lon_0=111 +k=1 +x_0=19500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 20
<4498> +proj=tmerc +lat_0=0 +lon_0=117 +k=1 +x_0=20500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 21
<4499> +proj=tmerc +lat_0=0 +lon_0=123 +k=1 +x_0=21500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 22
<4500> +proj=tmerc +lat_0=0 +lon_0=129 +k=1 +x_0=22500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger zone 23
<4501> +proj=tmerc +lat_0=0 +lon_0=135 +k=1 +x_0=23500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 75E
<4502> +proj=tmerc +lat_0=0 +lon_0=75 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 81E
<4503> +proj=tmerc +lat_0=0 +lon_0=81 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 87E
<4504> +proj=tmerc +lat_0=0 +lon_0=87 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 93E
<4505> +proj=tmerc +lat_0=0 +lon_0=93 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 99E
<4506> +proj=tmerc +lat_0=0 +lon_0=99 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 105E
<4507> +proj=tmerc +lat_0=0 +lon_0=105 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 111E
<4508> +proj=tmerc +lat_0=0 +lon_0=111 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 117E
<4509> +proj=tmerc +lat_0=0 +lon_0=117 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 123E
<4510> +proj=tmerc +lat_0=0 +lon_0=123 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 129E
<4511> +proj=tmerc +lat_0=0 +lon_0=129 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / Gauss-Kruger CM 135E
<4512> +proj=tmerc +lat_0=0 +lon_0=135 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 25
<4513> +proj=tmerc +lat_0=0 +lon_0=75 +k=1 +x_0=25500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 26
<4514> +proj=tmerc +lat_0=0 +lon_0=78 +k=1 +x_0=26500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 27
<4515> +proj=tmerc +lat_0=0 +lon_0=81 +k=1 +x_0=27500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 28
<4516> +proj=tmerc +lat_0=0 +lon_0=84 +k=1 +x_0=28500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 29
<4517> +proj=tmerc +lat_0=0 +lon_0=87 +k=1 +x_0=29500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 30
<4518> +proj=tmerc +lat_0=0 +lon_0=90 +k=1 +x_0=30500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 31
<4519> +proj=tmerc +lat_0=0 +lon_0=93 +k=1 +x_0=31500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 32
<4520> +proj=tmerc +lat_0=0 +lon_0=96 +k=1 +x_0=32500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 33
<4521> +proj=tmerc +lat_0=0 +lon_0=99 +k=1 +x_0=33500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 34
<4522> +proj=tmerc +lat_0=0 +lon_0=102 +k=1 +x_0=34500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 35
<4523> +proj=tmerc +lat_0=0 +lon_0=105 +k=1 +x_0=35500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 36
<4524> +proj=tmerc +lat_0=0 +lon_0=108 +k=1 +x_0=36500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 37
<4525> +proj=tmerc +lat_0=0 +lon_0=111 +k=1 +x_0=37500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 38
<4526> +proj=tmerc +lat_0=0 +lon_0=114 +k=1 +x_0=38500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 39
<4527> +proj=tmerc +lat_0=0 +lon_0=117 +k=1 +x_0=39500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 40
<4528> +proj=tmerc +lat_0=0 +lon_0=120 +k=1 +x_0=40500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 41
<4529> +proj=tmerc +lat_0=0 +lon_0=123 +k=1 +x_0=41500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 42
<4530> +proj=tmerc +lat_0=0 +lon_0=126 +k=1 +x_0=42500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 43
<4531> +proj=tmerc +lat_0=0 +lon_0=129 +k=1 +x_0=43500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 44
<4532> +proj=tmerc +lat_0=0 +lon_0=132 +k=1 +x_0=44500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger zone 45
<4533> +proj=tmerc +lat_0=0 +lon_0=135 +k=1 +x_0=45500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 75E
<4534> +proj=tmerc +lat_0=0 +lon_0=75 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 78E
<4535> +proj=tmerc +lat_0=0 +lon_0=78 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 81E
<4536> +proj=tmerc +lat_0=0 +lon_0=81 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 84E
<4537> +proj=tmerc +lat_0=0 +lon_0=84 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 87E
<4538> +proj=tmerc +lat_0=0 +lon_0=87 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 90E
<4539> +proj=tmerc +lat_0=0 +lon_0=90 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 93E
<4540> +proj=tmerc +lat_0=0 +lon_0=93 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 96E
<4541> +proj=tmerc +lat_0=0 +lon_0=96 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 99E
<4542> +proj=tmerc +lat_0=0 +lon_0=99 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 102E
<4543> +proj=tmerc +lat_0=0 +lon_0=102 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 105E
<4544> +proj=tmerc +lat_0=0 +lon_0=105 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 108E
<4545> +proj=tmerc +lat_0=0 +lon_0=108 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 111E
<4546> +proj=tmerc +lat_0=0 +lon_0=111 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 114E
<4547> +proj=tmerc +lat_0=0 +lon_0=114 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 117E
<4548> +proj=tmerc +lat_0=0 +lon_0=117 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 120E
<4549> +proj=tmerc +lat_0=0 +lon_0=120 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 123E
<4550> +proj=tmerc +lat_0=0 +lon_0=123 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 126E
<4551> +proj=tmerc +lat_0=0 +lon_0=126 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 129E
<4552> +proj=tmerc +lat_0=0 +lon_0=129 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 132E
<4553> +proj=tmerc +lat_0=0 +lon_0=132 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>
# CGCS2000 / 3-degree Gauss-Kruger CM 135E
<4554> +proj=tmerc +lat_0=0 +lon_0=135 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs <>