适用于Android和iOS的离线地图SDK

编程入门 行业动态 更新时间:2024-10-25 06:20:30
本文介绍了适用于Android和iOS的离线地图SDK的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我想为我的应用程序使用离线地图功能。有人可以推荐任何有用的地图SDK吗?

我发现这些: Skobbler , Bing地图 和 TomTom 。但不知道哪一个更好。我需要一个自定义兴趣点,路线highligting,并有一些信息失败。

是否可以使用谷歌地图,一些预先下载的地图用于脱机使用?

感谢您的任何建议。

解决方案

通过Android上的GoogleMap API和iOS上的MapKit SDK,您可以实现自定义图块提供程序。这意味着您可以选择叠加多段线和标记的地图块。这样做的好处在于,您仍然可以获得内置映射API的全部功能,但增加了实现离线映射的功能。

您可以通过映射像 OpenStreetMaps (许多大公司都使用它)。

  • 您可以下载整个数据集并将其与应用程序捆绑在一起,以便在用户下载应用程序时已经下载了切片。这将大大增加你的应用程序的大小。
  • 或者你实现一些离线切片缓存。这意味着要离线访问磁贴,用户必须在某个时间点看到在线地图的一部分。您需要处理切片的缓存。
  • 例如,您可以下载所需区域的切片。你问用户是否希望下载英国的整个数据集。这会减少应用程序的大小,同时使整个英国可以脱机使用。

这些只是一些想法。希望它有帮助。

I would like to use offline map functionality for my application. Could somebody recommend to any useful map SDK?

I found these: Skobbler, Bing Maps, and TomTom. But in not sure which one is better. I need a custom POI, routes highligting, and bubless with some information.

Is possible to use google maps, with some pre-downloaded maps for offline use?

Thanks for any advice.

解决方案

With the GoogleMap API on Android and the MapKit SDK on iOS you can implement custom tile providers. This means you can choose the map tiles that your polylines and markers are overlaid on. The beauty of this is you still get the full functionality of the built in mapping APIs but with the added ability to implement offline maps.

You have a few options with a mapping provider like OpenStreetMaps (which is used by many major companies).

  • You could download the entire data set and bundle it with your application so the tiles are already downloaded when the user downloads your app. This will greatly increase the size of your application.
  • Or you implement some offline tile caching. This means that to access the tiles offline the user would have to have seen that part of the map online at some point. You would need to handle the caching of the tiles.
  • You download the tiles for just the area you need them eg. you ask the user if they wish to download the entire data set for the UK. This would reduce the size of the application whilst making the entire UK available offline.

These are just some ideas. Hope it helps.

更多推荐

适用于Android和iOS的离线地图SDK

本文发布于:2023-11-15 03:00:30,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1590552.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:离线   适用于   地图   iOS   Android

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!