Using Maps API and Geolocation in libgdx

青春壹個敷衍的年華 提交于 2019-12-23 04:18:21

问题


Is there a way to embed or implement somehow Geolocation (via GPS or whatever method) and using maps from Google Maps or OSM in applications using libgdx? I can't find APIs or documentation regarding this, to implement an application using real world maps and Augmented Reality.


回答1:


I was able to use Google Maps V2 Api with libgdx. You can use Markers, get Location and display it in a Scene2d Label, also you can show or hide the map.

I wrote example code Github




回答2:


Better late than never?

I have started to implement such an extension for Libgd with open street maps. It does currently load, cache and render the map tiles. You are also able to zoom, and pan the map. In future updates searching for geo locations will also be possible.

Github: https://github.com/aspic/libgdx-maps



来源:https://stackoverflow.com/questions/16145254/using-maps-api-and-geolocation-in-libgdx

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!