osmdroid - Openstreetmap Tools for Android - Map App

osmdroid is a (almost) full/free replacement for Android's MapView (v1 API) class. It also includes a modular tile provider system with support for numerous online and offline tile sources and overlay support with built-in overlays for plotting icons, tracking location, and drawing shapes.

Current Release: 6.1.10 Jan 30, 2021

Current Development version: 6.1.11-SNAPSHOT

Next Release Version (planned): 6.1.11

Note: check your calendar, it may take up to a few days for all global mirrors to update.

Please read the osmdroid wiki for tutorials on integration.

Gradle dependency

repositories {
        mavenCentral()
}

dependencies {
    compile 'org.osmdroid:osmdroid-android:<VERSION>'
}

Be sure to replace <VERSION> with the last release version above.

Maven dependency

<dependency>
  <groupId>org.osmdroid</groupId>
  <artifactId>osmdroid-android</artifactId>
  <version><VERSION></version>
  <type>aar</type>
</dependency>

Platform or API Level (API level 8 = Platform 2.2)

<platform>8</platform>

You can also compile osmdroid from source or download the dependency directly from OSS or download the distribution package

Want the latest and greatest?

We periodically publish snapshots to maven central. If you're interesting in trying it out, using the following:

repositories {
    mavenCentral()
    maven{
        url  'https://oss.sonatype.org/content/repositories/snapshots/'
        name 'OSS-Sonatype'
    }
}
dependencies {
    compile 'org.osmdroid:osmdroid-android:<VERSION>-SNAPSHOT:debug@aar'
}

Use at your own risk though, it may not be stable or may have bugs or performance issues. If you run across any, please report them.

In case gradle doesn't resolve it, it can be download manually here: https://oss.sonatype.org/service/local/repositories/snapshots/content/org/osmdroid/osmdroid-android/-SNAPSHOT/osmdroid-android--SNAPSHOT.aar

Side note: gradle's cached dependencies and doesn't really handle snapshot very well. To force gradle to update snapshots on every build, try adding this to your root build.gradle file.

allprojects  {
  // forces all changing dependencies (i.e. SNAPSHOTs) to automagicially download
    configurations.all {
        resolutionStrategy {
            cacheChangingModulesFor 0, 'seconds'
    }
}

You can also build your project using the gradle option --refreshDependencies

OK now what?

Continue reading here, How-to-use-the-osmdroid-library

Related and important wiki articles

I have a question or want to report a bug

If you have a question, please view the osmdroid FAQ.
You can also view the Stack Overflow osmdroid tag and osmdroid Google Group where you can get feedback from a large pool of osmdroid users.

If you still have an issue, please check the Changelog page to see if this issue is fixed in a newer or upcoming version of osmdroid.

If think you have a legitimate bug to report then go to the 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值