[Tilecache] how to calculate resolution

Roman Rachkov roman.rachkov at gmail.com
Thu Mar 29 11:39:28 EDT 2007


I have layer in tilecache.cfg:


[vt]
type=MapnikLayer
mapfile=/usr/local/web/www/tilecache/data/vt.xml
bbox=-20037508.34, -20037508.34, 20037508.34, 20037508.34
srs=OSGEO:41001

without MaxResolution I can to get ideal image, but if I set:

[vt]
type=MapnikLayer
mapfile=/usr/local/web/www/tilecache/data/vt.xml
bbox=-20037508.34, -20037508.34, 20037508.34, 20037508.34
srs=OSGEO:41001
maxResolution=156543.03390625

I get this error:

An error occurred: couldn't calculate tile index for layer vt from
([2848114.2718949998, 5291494.1623579999, 2856386.5208609998,
5297354.1745779999])
  File "/usr/local/web/www/tilecache/TileCache/Service.py", line 459,
in cgiHandler
    format, image = service.dispatchRequest( params, path_info, host )
  File "/usr/local/web/www/tilecache/TileCache/Service.py", line 380,
in dispatchRequest
    tile = WMS(self).parse(params, path_info, host)
  File "/usr/local/web/www/tilecache/TileCache/Service.py", line 115, in parse
    return self.getMap(param)
  File "/usr/local/web/www/tilecache/TileCache/Service.py", line 124, in getMap
    % (layer.name, bbox))

How to calculate maxResolution and resolution for this bbox?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/tilecache/attachments/20070329/3257dbfb/attachment.html


More information about the Tilecache mailing list