[OpenLayers-Users] resolution index difference on OL 2.7 and OL2.11

ibrahim saricicek ibrahimsaricicek at gmail.com
Tue Mar 27 04:33:58 EDT 2012


Hi All,

Want to use Google V3 and decided to upgrade to OL 2.11...

This is map options;

    var options =
    {
        projection: new OpenLayers.Projection("EPSG:900913"),
        displayProjection: new OpenLayers.Projection("EPSG:4326"),
        units: "m",
        maxResolution: 4891.9698093750003,
        minResolution: 1.1943285667419434,
        maxExtent: new OpenLayers.Bounds(-20037508, -20037508, 20037508,
20037508.34),
        tileSize: new OpenLayers.Size(256,256),
        numZoomLevels: 15,
        allOverlays: false
    };

On Openlayers 2.7 this layer works fine;

myLayer = new OpenLayers.Layer.WMS('wmsTitle',
        'mapserverTilecacheUrl', {layers: 'wmsLayerName', format:
'image/png'},
        {'isBaseLayer': true, displayOutsideMaxExtent: false, buffer : 0}
    );

But on Openlayers 2.10 and 2.11 says;

An error occurred: can't find resolution index for 42.196661. Available
resolutions are: [156543.03390000001, 78271.516950000005,
39135.758475000002, 19567.879237500001, 9783.9396187500006,
4891.9698093750003, 2445.9849046875001, 1222.9924523437501,
611.49622617187504, 305.74811308593752, 152.87405654296876,
76.43702827148438, 38.21851413574219, 19.109257067871095,
9.5546285339355475, 4.7773142669677737, 2.3886571334838869,
1.1943285667419434, 0.59716428337097172, 0.29858214168548586]

Only works with resolution index: 76.43702827148438

What should I do now?

Thanks in Advance...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120327/81199011/attachment.html


More information about the Users mailing list