logo separator

[mkgmap-dev] low-res-opt branch: error message from ShapeSplitter for self-intersecting multipolygon

From Gerd Petermann gpetermann_muenchen at hotmail.com on Mon Jun 14 09:28:57 BST 2021

Hi Ticker,

I am still testing with the files in https://files.mkgmap.org.uk/download/507/xxx.zip

I applied the attached patch to enable massive merging and simulating possible splits and your splitShapeFix_10_lowRes.patch and I see several error messages.
The previously attached example comes from xxx\63240004.osm.pbf

My options:
--output-dir=e:\ld  --gmapi --generate-sea=multipolygon,floodblocker --preserve-element-order --order-by-decreasing-area
--allow-reverse-merge   --improve-overview --min-size-polygon=2
-c e:\xxx\template.args

Gerd

________________________________________
Von: mkgmap-dev <mkgmap-dev-bounces at lists.mkgmap.org.uk> im Auftrag von Ticker Berkin <rwb-mkgmap at jagit.co.uk>
Gesendet: Montag, 14. Juni 2021 10:19
An: Development list for mkgmap
Betreff: Re: [mkgmap-dev] low-res-opt branch: error message from ShapeSplitter for self-intersecting multipolygon

Hi Gerd

Any form of self-intersection might cause problems to ShapeSplitter.
Not sure what you mean by "connected hole visited.." - I presume
something like the outer edge of the shape is clockwise, with a cut
leading to a hole that is also clockwise; for this to happen the in/out
lines from the edge to the hole conceptually cross.

I'm just running low-res-opt on BritishIsles with ShapeMergeFilter
maxPoints=65535 to see if I can get a problem to work on. What is your
test area?

Also, the latest development versions of the suspect code areas are in
different branches. Should I attempt to have a composite with the
faster-mp bits of MP handling and low-res-opt version of
ShapeMergeFilter?

Your attached example looks OK and I wouldn't have expected it to cause
any difficulties for the later versions of ShapeSplitter. A possible
difficulty might be an almost horizontal line close to the in/out lines
to the lower shape. I hope my attempt to allow a bit of tolerance where
calculated points on the cut-line end up 1/2 HP units the wrong way
round isn't causing other problems. Do you have this as an example I
can test?

Ticker


On Sun, 2021-06-13 at 14:17 +0000, Gerd Petermann wrote:
> Hi Ticker,
>
> OK, my current understanding is that ShapeSplitter may fail to split
> 8-like shapes or shapes where the connected hole is visited in the
> "wrong" direction. Those problem cases are possibly created by
> 1) MultipolygonRelation.joinways()
> 2) MultipolygonCutter
> 3) ShapeMergeFilter (maybe)
>
> Do you see a way to avoid them in those routines? Attached is another
> example that doesn't work.
>
> Gerd

_______________________________________________
mkgmap-dev mailing list
mkgmap-dev at lists.mkgmap.org.uk
https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.patch
Type: application/octet-stream
Size: 4294 bytes
Desc: test.patch
URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20210614/f9827e73/attachment.obj>


More information about the mkgmap-dev mailing list