opensciencemap / vtm

a vector-tile map library written in java - running on android, desktop and within the browser
GNU Lesser General Public License v3.0
238 stars 176 forks source link

Using more than 1 BitmapTileLayer does not work as expected #103

Open stleusc opened 10 years ago

stleusc commented 10 years ago

I have one Tileserver serving overlay tiles that show POIs. I want to overlay this onto other BitmapTiles. I add the bottom layer with xxx.layers().add(1, bottomLayer); and then xxx.layers().add(2, overlayLayer);

When bottomLayer is a BitmapTileLayer then overlayLayer does not get displayed. When I replace bottomLayer with a OsmTileLayer both layers show.

I noticed that giving overlayLayer index 1 and bottomLayer index 2 works if both are BitmapTiles. Seems like the draworder is wrong in this case?!

Any idea?

hjanetzek commented 10 years ago

What are you using for the overlayLayer?

stleusc commented 10 years ago

both layers are BitmapTileLayer, one of them is mainly transparent with a few POIs in it.

hjanetzek commented 10 years ago

alpha bitmap tile layers work for me when adding

mMap.layers().add(new BitmapTileLayer(mMap, new DefaultSources.HillShadeHD()));

to the end of the examples BitmapTileActivity.onCreate.