I am using the following to define my map:
options = {
projection: "EPSG:900913",
units: "m",
maxResolution: 156543.0339,
numZoomLevels: 18,
maxExtent: new OpenLayers.Bounds(-20037508, -20037508,
20037508, 20037508.34)
};
map = new OpenLayers.Map('map',options);
Then my layer:
var sat = new OpenLayers.Layer.Google(
"Google",
{'sphericalMercator': true}
);
What the sphericalMercator true does is run the
initMercatorParameters: function() {
// set up properties for Mercator - assume EPSG:900913
this.RESOLUTIONS = [];
var maxResolution = 156543.0339;
for(var zoom=0; zoom<=this.MAX_ZOOM_LEVEL; ++zoom) {
this.RESOLUTIONS[zoom] = maxResolution / Math.pow(2, zoom);
}
this.units = "m";
this.projection = "EPSG:900913";
},
The maxResolution of 156543.0339 is based on (20037508.34 + 20037508) / 256.
I need a different Resolution but I still want the forward and inverse
mercator functions to work. Where are all the different places to change
the resolution? I need it based on a tile that is not 256 in size. I have
tried changing this in initMercatorParameters, the map, but It still does
not seem to play nice.
Thanks,
Linda Rawson
_______________________________________________
Users mailing list
[email protected]
http://openlayers.org/mailman/listinfo/users