logo separator

[mkgmap-dev] Too many pois on multipolygon areas

From WanMil wmgcnfg at web.de on Tue Sep 27 22:28:25 BST 2011

> WanMil schrieb am 27.09.2011 19:27:
>> Maybe it's not be too difficult to fix that. Here is my idea:
>> Just before the style conversion one point for each polygon is added
>> with a copy of all tags plus mkgmap:poly2poi=true. Polygons contained in
>> or created by a multipolygon are excluded but additionaly one point for
>> each multipolygon is added.
>>
>> Now the rules in the points style are applied automatically.
>
> I think you also have to change the style file, so that all the polygons created
> by the mp processing are not used by the style conversion. This should be easy
> by checking that there is no mkgmap:mp_created tag.

Do I understand you correct?: The polygons style should be used for 
polygons created by mp processing but only one POI should be created for 
the whole multipolygon and not one for each mp created polygon.

>
> I think (in a first step) you need not to care, whether teh created POI is
> within the mp area or within a hole, because also for normal (concave) polygons
> right now it is not ensured, that the created POI is within the polygon.

Yep.
First step: use the center point of a geometry. Don't care if it's in or 
out.

Further step: Maybe someone likes to implement the straight skeleton 
algorithm (http://en.wikipedia.org/wiki/Straight_skeleton). This could 
be used to find a quite perfect point which is guaranteed to be inside 
the geometry. If you have the straight skeleton you can choose the point 
on the skeleton with the greatest distance to an end point of the skeleton.

>
> Gruss
> Torsten

WanMil



More information about the mkgmap-dev mailing list