[OSM-dev] different rendering with mapnik based on area?
Reinder Verlinde
zwartgat at mac.com
Tue Apr 3 22:21:16 BST 2012
In article <4F79A860.2010709 at mazdermind.de>,
Peter Korner <osm-lists at mazdermind.de> wrote:
> > * Sven Geggus<lists at fuchsschwanzdomain.de> [2012-03-31 16:06 +0000]:
> >> is it possible to have different rendering rules based on the area
> >> where rendring takes place using an ordinary mapnik rendering stack
> >> (osm2pgsql+mod_tile+tirex)?
>
> It won't work without adapting the source. You can choose which source
> you want to adapt:
> - The Style: use different layers for the areas whith 'SELECT WHERE
> ST_Inside(way, ...)'-style queries - simple but slow
Alternatively, cache the return value of that ST_Inside call in a
separate column. Fast at query time, but with some database overhead.
You could even do it in a single layer, if your styling allows you to
adjust styles depending on that ST_Inside column.
Reinder
More information about the dev
mailing list