[OSM-talk] simplifying mapnik layout definition

Martijn van Oosterhout kleptog at gmail.com
Tue May 27 19:39:12 BST 2008


On Tue, May 27, 2008 at 7:29 PM, Robert (Jamie) Munro <rjmunro at arjam.net> wrote:
> Here's some working code that simplifies the file:
> sed "s/(\[bridge] = 'yes' or \[bridge]='true')/isBridge/g" osm.xml
>
> And the reverse:
> sed "s/isBridge/([bridge] = 'yes' or [bridge]='true')/g"

I'm thinking of teaching osm2pgsql and Mapnik about booleans at some
point so that all the comparisons against yes/no/1/0/on/off/etc all
get done during import. For this to work Mapnik needs to be able to
handle comparing different types, I sent a patch to Jon to do this so
hopefully at some point we can simplify at least that portion...

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




More information about the talk mailing list