[OSM-talk] How to georeference OSM Mapnik tiles?

Martijn van Oosterhout kleptog at gmail.com
Fri Nov 30 10:28:19 GMT 2007


On Nov 30, 2007 11:13 AM, Rahkonen Jukka <Jukka.Rahkonen at mmmtike.fi> wrote:
> I would like to convert some OSM tiles to geotiff format, but I wonder how
> can I get the georeferencing information I need for it. What I would need to
> know is:
> - Which projection the tiles are in (EPSG code or projection parameters)

It's not as official projection, though people refer to it as
EPSG:90013. It's also known as spherical mercator, the same as google
uses. The usual definition is:
+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0
+y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs
> - Pixel size for each zoom level
Zoom 0 is 256x256, each zoomlevel down is twice as big as the previous
in each dimension
> - What is the anchor point of the tile and its corresponding coordinates
Zoom 0 has 1x1 tiles, Each zoomlevel down has twice as many in each direction

So tile numbers are from 0 to 2^(zoom level)-1. See also:
http://wiki.openstreetmap.org/index.php/Slippy_map_tilenames

> Number 15 is obviously the zoom level, and from values 18653 and 9484 I
> guess I should be able to conclude somehow the anchor point.  But in what
> projection the tiles are, and what are the units and pixel sizes used for
> each zoom level?  Or do I have some better or more direct way for getting an
> excerpt of Mapnik layer in geotiff format?

This is just our mapnik layer though. You can setup your own mapnik
layer in any projection you like with tiles and resolution and size
you want.

Have a nice day,
-- 
Martijn van Oosterhout <kleptog at gmail.com> http://svana.org/kleptog/




More information about the talk mailing list