Why not ask your question on the new OpenStreetMap Community Forum?


I'd like to render my own maps with bounding box overlays. I do not wish to use tiles since the application will require multiple requests, therefore burdening the OSM servers, and I have enough knowledge to set Mapnik up myself.

However, Mapnik seems to just be a map renderer. I'd like to render static map cutouts with bounding box overlays over the map region. This seems to only be possible via software like OpenLayers, which only work on webpages. (The desired output must be a static image!)

I guess my question is this:

For rendering static images of regions on a map,

  • Is Mapnik overkill, or is it necessary?
  • Does Mapnik (or similar software) render city labels and state/county/city boundary lines? (Region is United States.)
  • What software would I use to stitch the map tiles together?
  • What software would I use to render overlays above my map?

Thanks in advance!

EDIT: Solutions in Python are preferred, but not required.

asked 23 Jul '14, 14:09

alberth's gravatar image

accept rate: 0%

edited 23 Jul '14, 14:20


Not a direct answer to the question but:

 I do not wish to use tiles since the application will require multiple requests, therefore burdening the OSM servers

One option would be to set up your own tile server.

(23 Jul '14, 16:07) SomeoneElse ♦

I haven't worked with the new CartoCSS way of describing styles to Mapnik, but you certainly can do what you want with Mapnik. You can define as may layers as you want selecting which features show in what layers. Finally, you can use local or non-OSM data in layers too. I did all this to create some specialized printed paper maps for an area. If you are not worrying about printer pixels per inch and what it takes to get a 1:24000 scaled printed image at, say 600dpi, they you can even crib from the web scale factor logic.

I don't really know Python but all the Mapnik examples I found were in Python so that is what I used. So yes, you can do it in Python too.

Software I used were: Mapnik, Postgresql and the gdal library for the basic map. I also used PHP in command line mode to set a color profile on the resultant image and turn everything to a PDF. Don't know if you can do that part in Python or not but since I know PHP and had the library for it that did PDF creation I used it.

permanent link

answered 23 Jul '14, 16:47

n76's gravatar image

accept rate: 17%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 23 Jul '14, 14:09

question was seen: 3,889 times

last updated: 23 Jul '14, 16:47

powered by OSQA