Ok, I solved this issue with the following lines:
OpenLayers.Util.onImageLoadError = function() {
this.src = "http://localhost/static/img/missingTile.png";
};
Where missingTile.png is a completely transparent image of size 256x256.
The visualization is now perfect on every browser, but using firebug on
Firefox I see that every missing tile produces a 404 error anyway.
Can this lead to performance issues and is it possible to avoid these calls?
Hi list.
I produce tiles using mapnik (www.mapnik.org) and I use the following
map definition:
var map = new OpenLayers.Map({
div: "map",
allOverlays: true,
maxExtent: bounds,
projection: fromProj,
displayProjection: toProj,
allowSelection: true,
controls: [new OpenLayers.Control.PanZoomBar(), new
OpenLayers.Control.Navigation()],
});
var layer = new OpenLayers.Layer.OSM(
layer_dir,
"tiles/${z}/${x}/${y}.png",
{zoomLevels: maxZoom, zoomOffset: minZoom, resolutions: res}
);
map.addLayer(layer);
The problem is that I have a visualization issue in IE and Chrome: the
missing tiles are represented as pink squares.
Instead in Firefox the visualization is perfect because it simply
uses a white background when the tile is missing.
Is there a map or layer parameter to visualize as white the missing
tiles?
Thanks in advance,
Alessandro
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users
--
Alessandro Candini
MEEO S.r.l.
Via Saragat 9
I-44122 Ferrara, Italy
Tel: +39 0532 1861501
Fax: +39 0532 1861637
http://www.meeo.it
========================================
"ATTENZIONE:le informazioni contenute in questo messaggio sono
da considerarsi confidenziali ed il loro utilizzo è riservato unicamente
al destinatario sopra indicato. Chi dovesse ricevere questo messaggio
per errore è tenuto ad informare il mittente ed a rimuoverlo
definitivamente da ogni supporto elettronico o cartaceo."
"WARNING:This message contains confidential and/or proprietary
information which may be subject to privilege or immunity and which
is intended for use of its addressee only. Should you receive this
message in error, you are kindly requested to inform the sender and
to definitively remove it from any paper or electronic format."
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users