gpt4 book ai didi

.net - 从坐标保存 map 图像

转载 作者:行者123 更新时间:2023-12-02 05:35:05 27 4
gpt4 key购买 nike

我需要做以下事情:我有一个划分 map 区域的坐标列表。有了这些坐标,我需要使用 map 提供程序(例如:谷歌地图、必应等)可视化该区域,并将获得的图像保存到文件中。

我正在 .net 2.0 框架中开发一个 c# 应用程序,是否存在可以帮助我执行此操作的库或调用?

最佳答案

您可以尝试使用 Google Static Maps API。由于来源:https://developers.google.com/maps/documentation/staticmaps/#Overview

The Google Static Maps API returns an image (either GIF, PNG or JPEG) in response to an HTTP request via a URL. For each request, you can specify the location of the map, the size of the image, the zoom level, the type of map, and the placement of optional markers at locations on the map. You can additionally label your markers using alphanumeric characters.

A Static Maps API image is embedded within an tag's src attribute, or its equivalent in other programming languages.

当您获得 img 源时,您可以在其中操作抛出 javascript(获取:Get image data in JavaScript? 和保存:http://www.html5canvastutorials.com/advanced/html5-canvas-save-drawing-as-an-image/)或使用服务器代码:https://stackoverflow.com/a/1272126/157666

关于.net - 从坐标保存 map 图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11825956/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com