Hello mapnik users,
Hello Artem,

I'm using mapnik 0.7.1 through python-2.6 bindings on Windows 2008 to
render osm data.

The use case is pretty simple:

m = mapnik.Map(512,256,"+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 +nadgri...@null +no_defs")
mapnik.load_map(m,'./osm/osm.xml')
bbox = mapnik.Envelope(mapnik.Coord(2906441.56,5532817.86),
mapnik.Coord(2907664.56,5533429.35))
m.zoom_to_box(bbox)
im = mapnik.Image(m.width,m.height)
map_output = 'map.png'
mapnik.render(m,im)
im.save(map_output)

The problem I'm facing is that if I modify Image's size, e.g.
im = mapnik.Image(m.width*2,m.height*2)

the generated image has a modified bounding box, which is something I
do not want.

So, my question is this: how can I make sure that the geographical
coordinates remain the same (e.g. specified through map.zoom_to_box),
no matter the resolution of the output image it is rendered into?

Thank you for any pointers,
George.
_______________________________________________
Mapnik-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/mapnik-users

Reply via email to