帮助使用 api 在 google 地图上绘制坐标

发布于 2024-10-01 17:26:18 字数 129 浏览 0 评论 0原文

我从外部数据库获得了这两个坐标 x 和 y。

X = 30490,y = 31430

试图弄清楚如何将这些坐标绘制到谷歌地图上?由于谷歌地图仅接受纬度和经度值...

非常感谢任何帮助!谢谢...

i have got these two coordinates x and y from an external database.

X = 30490, y = 31430

was trying to figure out how to plot these coordinates on to google map? As google map only accept lat and lon value...

Any help is most appreciated!! Thanks...

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

听不够的曲调 2024-10-08 17:26:18

您将需要知道用于这些坐标的坐标系。有数百个甚至数千个“官方”坐标系!

一旦有了坐标系,您就可以将坐标转换为 Google 使用的坐标(经度、纬度 WGS84,球形地球)。

您可能想要离线进行转换,但如果您使用 JavaScript 在线进行转换,那么请查看 Proj4JS 库。

对于离线使用,标准开源库是 Proj.4,但如果这是您第一次体验地理坐标系和地图投影,这可能有点令人畏惧。

You will need to know the coordinate system that was used for those coordinates. There are hundreds if not thousands of 'official' coordinate systems!

once you have the coordinate system, you can transform the coordinates to those used by Google (Longitude, Latitude degrees WGS84 with a spherical Earth).

You may want to do the transformation offline, but if you are doing it online with JavaScript, then take a look at the Proj4JS library.

For offline use, the standard open source library is Proj.4 but that is probably a bit daunting if this is your first experience with geographic coordinate systems and map projections.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文