[MapProxy] MapProxy serving gdal2tiles output
Paul Norman
penorman at mac.com
Wed Nov 28 13:32:24 PST 2012
> From: mapproxy-bounces at lists.osgeo.org [mailto:mapproxy-
> Subject: Re: [MapProxy] MapProxy serving gdal2tiles output
>
> > What I am doing is defining a cache without a source, giving the
> directory where the tile structure is located.
> > I followed the documentation and some information I got asking on IRC
> and this is my yaml file so far:
> > http://pastebin.com/wAkM4G2d
>
> This looks good. The tricky part will be to configure the right grid of
> your tiles. I don't know how gdal2tiles works for non-4326/3875 images.
> Does gdal2tiles give you some information (resolutions, bbox)?
> I would remove min_res and add all resolutions that are tiled.
By default gdal2tiles uses the OGC TMS spec instead of the Google/OSM one.
It's fairly trivial to convert between these with a shell script.
I have a source which is gdal2tiles generated and what I did was copy up to
z18 to my remote server and then have it fetching z19 and z20 from my home
server. The grid definition I used is
z20:
# About 100mm/px in Vancouver
base: GLOBAL_MERCATOR
origin: ul
num_levels: 21
The relevant cache and source are
surrey2011_cache:
grids: [z20]
sources: [merry_surrey2011_tms]
format: image/png
cache:
type: file
directory_layout: tms
merry_surrey2011_tms:
type: tile
url: http://home.server.name/tiles/Surrey2011/%(tms_path)s.png
grid: z20
transparent: true
coverage:
polygons: 'wkt/surrey2011.wkt'
polygons_srs: 'EPSG:4326'
I believe all you'd have to do to use the OCG TMS numbering is change the
origin.
More information about the MapProxy
mailing list