Adding Overlay to OSMDROID

前端 未结 3 1148
难免孤独
难免孤独 2020-12-14 04:42

I have been struggling with this long time. I am trying to add Overlay on my map. I am using the open source OSMdroid. but all I get by the example is a straight red line fr

3条回答
  •  感情败类
    2020-12-14 05:20

    If you are trying to add an icon, then you want to look at the ItemizedOverlay classes. You can use osmdroid's ItemizedIconOverlay which is a concrete implementation of ItemizedOverlay, or you can subclass ItemizedOverlay on your own. Take a look at the samples, such as:

    http://code.google.com/p/osmdroid/source/browse/trunk/OpenStreetMapViewer/src/org/osmdroid/samples/SampleWithMinimapItemizedoverlay.java

提交回复
热议问题