简体   繁体   English

如何在Google Map(Android片段)上显示(公开可用的,即非本地的)KML文件

[英]How to display (publicly available i.e. non-local) KML file on a Google Map (Android fragment)

I am trying to find a way to display a KML layout over a Google Map in my Android application. 我正在尝试寻找一种在Android应用程序中的Google Map上显示KML布局的方法。 The KML file itself is hosted on Google App Engine (publicly accessible). KML文件本身托管在Google App Engine(可公开访问)上。 I have seen many posts regarding manually parsing locally-stored KML files, but it isn't clear to me if this is something you only have to do if you are trying to display a local KML file. 我已经看到很多有关手动解析本地存储的KML文件的帖子,但是我不清楚这是否只是在您试图显示本地KML文件时要做的事情。 However, I have not seen any evidence of a different straight-forward way to display publicly available KML files. 但是,我没有看到任何证据来显示公开可用的KML文件的另一种直接方法。 Google's KML support for Google Maps Mobile ( https://developers.google.com/kml/documentation/mapsSupport#googlemapsformobile ) seems to imply that displaying KML files directly in Google Maps is indeed supported. Google对Google Maps Mobile的KML支持( https://developers.google.com/kml/documentation/mapsSupport#googlemapsformobile )似乎暗示着确实支持直接在Google Maps中显示KML文件。

Is there any way to display a publicly accessible (by public URL) KML layer file over a Google Map in Android without manually parsing the file??? 有没有办法在不手动解析文件的情况下在Android的Google Map上显示可公开访问(通过公共URL)的KML图层文件???

如果您想显示两点之间的路线,这应该对您有帮助: http : //blog.synyx.de/2010/06/routing-driving-directions-on-android-part-1-get-the-route /

I had the same problem lately and the only solution I've seen was parsing the KML file. 最近,我遇到了同样的问题,我看到的唯一解决方案是解析KML文件。 It's not that complicated, KML is kind of a XML file, you know the tags and you can parse it easily. 并不是那么复杂,KML是一种XML文件,您知道标记并且可以轻松对其进行解析。

Google is trying to make it better and lately and they have built a new app for this. Google正在努力使它变得更好并且最近,他们为此构建了一个新的应用程序。 Look: https://play.google.com/store/apps/details?id=com.google.android.apps.m4b 外观: https//play.google.com/store/apps/details?id = com.google.android.apps.m4b

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在谷歌地图片段android studio中导入KML多边形文件 - How to import a KML polygon file in google map fragment android studio 如何在Android中解析KML文件并将其显示在Google地图中? - How to Parse KML file in android and display it in Google maps? 在Android上的Google地图中打开本地KML文件 - Open local KML File in Google Maps on Android 如何使用 Xamarin.Z6450242331912982ACA6663 下载公开可用的 Android X 和 iOS 上的文件? - How do I download a file on both Android X and iOS that is publicly available, using Xamarin.Forms? KML点数无法显示在Android Google地图上 - KML Points Can't Display on Android Google Map 如何在片段中显示Google Map? - How to display Google Map in fragment? 如何在Android的Google地图上显示可用的Wifi热点? - How to Display Available Wifi hot-spots on google map in android? 使用Osmdriod在地图上显示Android设备内存中的KML文件 - Display the KML file from Android device memory on the map using Osmdriod 如何将我的活动显示在Android联系人菜单中,例如facebook app? - How can I have my activity display in android contact menu, like i.e. facebook app? 如何在非本地网络上以编程方式通过 Internet 连接 windows 和 android 设备 - How to connect windows and android device over internet programmatically on Non-Local network
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM