[Tilecache] Mercator calculations ( GMaps ) for tilecache Layer.py

Christopher Schmidt crschmidt at metacarta.com
Sun Mar 25 08:00:04 EDT 2007


On Sun, Mar 25, 2007 at 01:34:08AM -0700, Bill Woodall wrote:
> Hi Christopher, Schuyler, & List
> 
> ** Work in Progress **
> 
> Attached is the lastest working copy of Layer.py and might not be the
> best form of python, but it works!   OK, with one small intermittent bug
> when using MetaTiles which I'm still tracking down :(
> 
> To use the code, add a line to your tilecache.cfg in the layer section
> like;
> 
> projtype=mercator
> 
> Here is a breakdown of the issues that stop the stock TC from generating
> tiles for overlays on a Google baselayer;
> 
>   * Google does not use square tiles
>   * Tiles lat changes as you move away from the equator
>     ( gets smaller as you move away )
>   * Tiles are number ( decimal degrees ) from North to 
>     South and West to East
> 
> So to address these, here is what is needed to get a Gmaps baselayer and
> overlays to play nice 
> *NOTE: I have mainly tested on WMS overlays so you mileage may vary

Bill:

Can you give an example request to the backend WMS server when using a
Mercator projection option?

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Tilecache mailing list