访问不同的 Bing 地图图层

发布于 2024-12-27 11:49:16 字数 181 浏览 5 评论 0 原文

API 是否有一部分用于访问不同的地图图层数据,例如人口热图、县边界或邮政编码线?

我知道这主要是由像 ESRI/ArcServer 这样的人处理的,但我很好奇是否有某种方法可以在电话平台上获取类似的信息。

在这一点上,我看到它的唯一方法是拥有一个巨大的数据集,解析它,然后自己绘制多边形。这在电话上听起来非常耗时。

Is there a part of the api for access different map layer data such as population heat maps, county boundaries or zipcode lines?

I know this is mostly handled by people like ESRI/ArcServer but I was curious is there was some way to get similar information on the phone platform.

At this point, the only way i see it, is to have a huge data set, parse it, and draw the polygons myself. This sounds extremely time consuming on a phone.

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

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

发布评论

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

评论(2

黯然 2025-01-03 11:49:17

可悲的是谷歌、必应地图等。除了预定义的道路、卫星样式等之外,不要公开对其数据集的访问。正如 tghamm 所建议的,在移动设备上获得高性能解决方案的最佳选择不是绘制动态多边形,而是预渲染您自己的多边形用于要显示数据的区域/缩放级别的栅格图块集,并将其显示为地图控件顶部的自定义图块图层。

创建此类图块集的一个很好的工具链是:

1.) 使用 SQL Server Express(或 PostGIS,如果您愿意)作为后端空间数据库 - http://www.microsoft.com/express/sql/ ($0)

2.) 以 shapefile 格式获取必要的数据 - http://www.diva-gis.org/Data ($0)

3.) 将 shapefile 数据加载到 SQL Server - http://www.sharpgis.net/page/shape2sql.aspx ($0)

4.) 编写一个查询以从 SQL Server 检索必要的信息(或检索它直接来自 shapefile)并使用 Mapnik 将其渲染为图块 - http://www.mapnik.org ($0)

总计成本,0 美元。

另外,请务必查看开放街道地图 - http://osm.org,它提供对整个数据库的访问您可以自己下载并渲染 - 在世界许多地区(尽管不是全部),它在数据的质量和完整性方面都击败了谷歌和微软。

Sadly Google, Bing Maps et al. don't expose access to their datasets in anything other than the pre-defined road, satellite styles etc. As tghamm suggests, your best bet for a performant solution on a mobile device is not to draw dynamic polygons, but pre-render your own raster tilesets for the area/zoom levels at which you want to display the data and display these as a custom tile layer ontop of the map control.

A good toolchain for creating such a tileset is:

1.) Use SQL Server Express (or PostGIS, if you prefer) as backend spatial DB - http://www.microsoft.com/express/sql/ ($0)

2.) Get necessary data in shapefile format - http://www.diva-gis.org/Data ($0)

3.) Load the shapefile data into SQL Server - http://www.sharpgis.net/page/shape2sql.aspx ($0)

4.) Write a query to retrieve the necessary information from SQL Server (or retrieve it directly from shapefile) and render it to tiles using Mapnik - http://www.mapnik.org ($0)

Total cost, $0.

Also, be sure to check out open street map - http://osm.org, which provide access to their entire database that you can download and render yourself - in many areas of the world (although not all) it beats both Google and Microsoft in quality and completeness of its data.

回心转意 2025-01-03 11:49:17

通常,这些数据是通过使用切片服务器来传递的,其中几何图形在服务器上渲染,然后切割成切片,以便客户端仅负责使用栅格数据。有很多地方可以获取优质图像:

http://www.census.gov/geo/www /老虎/
这是了解美国基本地缘政治形态的良好起点。

从那里,有一些第三方库能够帮助您直接使用这些 SHP 文件,例如 http://www. thinkgeo.com/

或者,有些人选择将 shp 文件的内容上传到支持空间类型的数据库结构中。我使用过 Sql Server 2008,一些 .Net 库对它进行了补充,以促进形状处理和渲染操作。

最后,可能有大量开放式切片服务器具有有用的数据层,您只需要了解要使用的切片模式,例如 WMS。

Often this data is delivered through use of a tile server, where the geometries are rendered on a server and then cut into tiles so that the client is only responsible for consuming the raster data. There's plenty of places to get good imagery:

http://www.census.gov/geo/www/tiger/
This is a good starting point for your basic geo-political shapes in the US.

From there, there are third party libraries capable of assisting you with consumption of those SHP files directly, such as http://www.thinkgeo.com/.

Alternatively, some people choose to upload the contents of the shp file into a db structure that supports spatial types. I've used Sql Server 2008, which is complimented by some .Net libraries to facilitate shape handling and manipulation for rendering.

Finally, there are likely a good number of open tile servers out there with useful data layers that you need only understand the tiling pattern to consume, e.g. WMS.

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