About the conversion of the domestic coordinate system

2022-10-19 While browsing Ruan Yifeng's weblog, I came across an article in Science and Technology Enthusiast Weekly (No. 225). The title of the article is "A Concise Guide to the Chinese Coordinate System" (English). I clicked in and took a look, and talked about the domestic coordinate system and some transformations of wgs84. I found it useful, so I wrote it in the blog and recorded it.

Original article link

A Concise Guide to the Chinese Coordinate System

A coordinate conversion algorithm is mentioned in it, and it also explains why the conversion from gcj02 to wgs84 is not provided in the official API. If the coordinates are applied to the Baidu map, the conversion experienced: wgs84 => gcj02 => bd-09. The article describes the implementation of coordinate transformations in different programming languages.

conversion logic

The author of the article implemented it using JavaScript and provided a github code repository at the address:

https://github.com/wandergis/coordtransform/blob/master/index.js 

Based on this conversion, a simple conversion is implemented inside the article to convert Baidu coordinates to wgs84. If it is a test, or to convert several Baidu coordinates, it is very useful.

The sample code is currently unavailable in China, so please paste the address first

https://gist.github.com/nomadrat/e496873e7c6be8496c0582174de611ba 

 

Guess you like

Origin blog.csdn.net/GhostPaints/article/details/127403217