[OpenLayers-Users] no scale control if only resolutions in map?
Richard Duivenvoorde
rdmailings at duif.net
Sat Mar 24 15:39:04 EDT 2007
Hi List,
I'm running mapserver map from geotiffs.
After some fiddling with scales, I ended up with a mapdefinition with
resolutions:
map = new OpenLayers.Map('map', {
'projection':'EPSG:28992',
'units':'m',
'maxExtent':newOpenLayers.Bounds(0,300000,300000,600000),
'resolutions':[1, 2.5, 5, 10, 256, 512]
} );
But now the scale control isn't showing up anymore....
If I look in: Scale.js I see:
updateScale: function() {
var scale = this.map.getScale();
if (!scale)
return;
So apparently there is no relation between resolutions and scales (or
calculating the one from the other )?
Question: can I show a scale-control with only resolutions defined? Or
should I calculate the scales from resolutions?
Grtz,
Richard
More information about the Users
mailing list