[OpenLayers-Users] Finding out available resolutions for tilecache

Adrian Popa adrian_gh.popa at romtelecom.ro
Thu Oct 15 08:47:02 EDT 2009


Hello everyone,

I'm trying to convert my WMS layer to use tilecache in the backend and I 
have stumbled over this problem which I can't solve yet:

Here is my request:
http://terra/cgi-bin/tilecache.cgi?MAP=%2Fvar%2Fwww%2Fhtml%2Fmap%2Frtc_base.map&TRANSPARENT=false&FORMAT=image%2Fpng2&MAP_IMAGETYPE=agg&TRANSITIONEFFECT=resize&LAYERS=rtc_base&MAXEXTENT=left-bottom%3D(20.26%2C43.16)%20right-top%3D(29.7%2C48.46)&MAXRESOLUTION=156543&UNITS=m&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&SRS=EPSG%3A900913&BBOX=-180,-90,180,270&WIDTH=256&HEIGHT=256

Here is the response of the server:

|An error occurred: can't find resolution index for 1.406250. 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]
||
|

I've read over the internet and it seems I need to set the same 
'resolutions' array in OpenLayers and in TileCache. No problem.
My question is: what is my "current" OpenLayers resolution? How can I 
find it?

Currently, my map has no special options set (about resolutions or zoom 
levels).

I've looked around the DOM, but the properties there only reflect what I 
set up at the map/layer creation.

Thanks.
Adrian

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20091015/9b2ae39e/attachment.html


More information about the Users mailing list