Subject: Re: [geometry] #8376: difference of non-closed polygons returns closed polygon
From: Volker SchÃ¶ch (vschoech_at_[hidden])
Date: 2014-10-10 04:39:35
> I tried this example as well (see attached program and output).
> What I see is that the output has 18 points (I can see that from both the dsv printout of the geometry, as well as from bg::num_points). So the resulting multi-polygon is not closed, but when you output it through bg::wkt, it is shown as closed.
Thank you very much for double-checking! In the mean time I, too, found that things may not be what they appear to be, but I could not yet nail it. Apparently, not only wkt but also read_wkt mix up the closedness. I got caught by this because I have a number of unit tests in place based on read_wkt, which are now triggering like crazy.
I'm glad that it's just wkt/read_wkt, and not the actual algorithm, that is at fault.
Should I file a ticket for the wkt/read_wkt issue? It interferes with debugging, unit-testing, and with reporting issues, too!
Volker SchÃ¶ch | vschoech_at_[hidden]
Senior Software Engineer
We are looking for C++ Developers: http://www.think-cell.com/career
think-cell Software GmbH | Chausseestr. 8/E | 10115 Berlin | Germany
http://www.think-cell.com | phone +49 30 666473-10 | US phone +1 800 891 8091
Amtsgericht Berlin-Charlottenburg, HRB 85229 | European Union VAT Id DE813474306
Directors: Dr. Markus Hannebauer, Dr. Arno SchÃ¶dl
Geometry list run by mateusz at loskot.net