[OSM-talk] osm2pgsql multipolygon parsing

"Petr Morávek [Xificurk]" petr at pada.cz
Mon Sep 23 17:55:57 UTC 2013


Dne 23.9.2013 16:03, Peter Wendorff napsal(a):
> Am 23.09.2013 15:20, schrieb "Petr Morávek [Xificurk]":
>>
>> I propose that:
>> 1) By default the relation and ways are treated separately
>>  - relation creates polygon with tags from the relation and ways are
>> processed on their own.
>> 2) If and only if the relation has only type=multipolygon tag go to
>> "backward compatibility mode". Copy over tags from outer ways that are
>> present on all of them and create polygon. Go over all member ways and
>> if all their tags are present on the created polygon, then mark them as
>> done, otherwise process them separately.
> 
> +0.75 ;)
> 
> Agree, but I would use (2) if and only if "backward compatibility mode"
> is active.
> Additionally I would not use the backward compatibility mode for the
> mapnik default sheet (after some time with big announcements an probably
> a tool detecting/reporting possible problems for fixing).
> 
> With this we could
> - "enforce" more correct tagging in future
> - engage the mappers community to fix where the bad-style tagging is
> used yet
> - gracefully allow any other application to fall back to the old style
> as long as they want to.
> 
> This might (!) degrade the perceived quality of the default mapnik layer
> for some time (!), but IMHO it's worth it as it simplifies multipolygon
> interpretation and on the long term teaches mappers to use the tagging
> that is correct and matches that simplified interpretation.
> 
> regards
> Peter

This is probably a good idea in the long-run, but there are things that
need to be done before this cut-off and all of them need a certain
transitional period.
1) You need to edit wiki and make people aware that this tagging scheme
is considered deprecated.
2) You need to make sure, that all the editors produce correct
multipolygon relations.
3) Fix the deprecated tagging on most of the elements.

I really don't think it's a good idea to suddenly stop rendering quarter
of the multipolygons out there just to enforce some thought-out
policy... I don't see who would benefit from this.


Anyway, this thread was not started to debate tagging schemes, the
question I (and others) wanted to discuss here is this:
Given the data that are currently in the database, how should osm2pgsql
handle the import to get as much as possible multipolygons right?


Best regards,
Petr Morávek aka Xificurk



More information about the talk mailing list