[OpenLayers-Users] Problem to show tiles of maperitive-render-tiles

Jan Tappenbeck osm at tappenbeck.net
Fri Jan 20 11:59:59 EST 2012


hi !

i have render some tiles for the area of europe - names only by 
zoom-level 4->10.

the layer is include by

var newLayer = new OpenLayers.Layer.OSM.Local("NewLayerLocal");
map.addLayer(newLayer);

additional in OpenStreetMap.js

OpenLayers.Layer.OSM.Local = OpenLayers.Class(OpenLayers.Layer.OSM, {

     initialize: function(name, options) {

         var url = [
             
"http://www.tappenbeck.net/osm/ferry2011/tiles/${z}/${x}/${y}.png"
         ];

         options = OpenLayers.Util.extend(
             { numZoomLevels: 19, isBaseLayer: false}, options);
         var newArguments = [name, url, options];
             OpenLayers.Layer.OSM.prototype.initialize.apply
             (this,newArguments);
     },

     CLASS_NAME: "OpenLayers.Layer.OSM.Local"
});



and you can show in 
http://osm.tappenbeck.net/ferry2011/deu/ferry_iframe_debug.php

the problem now is when the zoom-level is 5 and higher the names of the 
north will repeat - but only in the vertical to the north.

did anyone have a idea ??

regards Jan :-)


More information about the Users mailing list