如何使用 geos 测量宽度(以公里为单位)
我有一个边界框,我想调整它,使其宽度不小于 2 公里。我从谷歌的地理定位服务中获取边界框,然后我在数据库中搜索其中的内容,但我想确保我不会针对任何小于 1 或 2 公里的东西进行测试..我想得到面积,测量高度,并在需要时以中心为中心展开。
我已经拥有了所有 SRID 和其他内容。
谢谢
I've got a bounding box, and I want to adjust it so it's not less than, say, 2km across. I get the bounding box from google's geolocate service, and then I search for stuff that's inside that in my database, but I want to make sure I don't test against anything smaller than 1 or 2km across.. I'd like to get the area, measure the with, height, and expand pivoting on the center in case it's needed.
I already have all the SRID and stuff right.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这个问题的答案取决于 SRID。您调用 Expand 获取无单位浮点数作为参数,其单位取决于定义 SRID 的单位。
The answer to this depends on the SRID. You call expand which gets a unitless float as a parameter, and the units on that depend on the units with which the SRID is defined.