We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
今天重新看了一下 wgs→gcj 里面对于 transform() 一滩浑水之后的两个数值的处理:
transform()
d.lat = (d.lat * 180.0) / ((earthR * (1 - ee)) / (magic * sqrtMagic) * Math.PI); d.lng = (d.lng * 180.0) / (earthR / sqrtMagic * Math.cos(radLat) * Math.PI);
这边实际上是进行了这样的操作:
// https://en.wikipedia.org/wiki/Latitude#Length_of_a_degree_of_latitude d.lat /= 椭球体纬线1°弧长({纬度: lat}) // https://en.wikipedia.org/wiki/Longitude#Length_of_a_degree_of_longitude d.lon /= 椭球体经线1°弧长({纬度: lat})
如果感兴趣的话可以加上注释说明。能得到的一个比较有意思的结论是可以从 GCJ 的 transform 函数中直接得到经纬方向上加偏的距离,以及 transform 这个步骤的返回变量可以尝试说明单位是米。
The text was updated successfully, but these errors were encountered:
OK
Sorry, something went wrong.
No branches or pull requests
今天重新看了一下 wgs→gcj 里面对于
transform()
一滩浑水之后的两个数值的处理:这边实际上是进行了这样的操作:
如果感兴趣的话可以加上注释说明。能得到的一个比较有意思的结论是可以从 GCJ 的 transform 函数中直接得到经纬方向上加偏的距离,以及 transform 这个步骤的返回变量可以尝试说明单位是米。
The text was updated successfully, but these errors were encountered: