纬度/经度列表内的点

发布于 2024-10-17 15:18:01 字数 456 浏览 2 评论 0原文

首先,我在force.com APEX 中对此进行编码。

我有一个谷歌地球 KML。在这个 KML 文件中,我有一系列坐标:

<coordinates>
    -73.920776,40.710476,0.000000
    -73.926125,40.705692,0.000000
    -73.933609,40.702782,0.000000
    ...
    ...
    -73.924210,40.714085,0.000000
    -73.922409,40.712849,0.000000
    -73.920776,40.710476,0.000000
</coordinates>

我想要做的是创建一个包含所有坐标的数组,然后能够检查给定的纬度/经度是否落在坐标内。我已经检查了多边形内的点,但想看看是否有更简单的方法。

谢谢 坦率

First, I'm coding this in force.com APEX.

I have a google earth KML. In this KML file I have a series of coordinates:

<coordinates>
    -73.920776,40.710476,0.000000
    -73.926125,40.705692,0.000000
    -73.933609,40.702782,0.000000
    ...
    ...
    -73.924210,40.714085,0.000000
    -73.922409,40.712849,0.000000
    -73.920776,40.710476,0.000000
</coordinates>

What I would like to do is create a array that has all my coordinates and then be able to check if a given lat/lon falls within the coordinates. I've reviewed the points within a polygon but would like to see if there is a simpler approach.

Thanks
Frank

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

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

发布评论

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

评论(1

淑女气质 2024-10-24 15:18:01

如果您的区域相对较小 - 不越过极点或国际日期变更线,那么多边形中的点就足够了。

If you have a relatively small area - which doesn't go over the pole or through the international date line then point in polygon is enough.

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