[geos-devel] Polygon simplicity and validity
mtnclimb at telus.net
Sat Sep 8 22:11:15 PDT 2012
Sean, FWIW I agree with you that it makes more sense to have isSimple
for polygons and rings report whether the underlying linework is simple.
The current JTS hard-coded implementation was done for sake of
expediency during the initial development of the library. It's a bit of
a wasted opportunity to not allow isSimple to report self-intersecting
linework (even if it still formally meets the SFS specification). I'll
look into enhancing this in JTS.
On 9/7/2012 12:06 PM, Martin Davis wrote:
> The OGC SFS specifies that valid polygons are simple by definition,
> presumably because valid polygons cannot contain any
> self-intersections. Because of this, JTS/GEOS simply returns true for
> Polygon.isSimple(), without attempting any inspection of the actual
> linework. isValid can be used to detect self-intersections.
> On 8/29/2012 11:19 AM, Sean Gillies wrote:
>> Is simplicity meaningful for polygons or only for lines? Here's a
>> single ring bowtie that GEOS 3.3.0 reports as invalid but simple:
>> POLYGON ((39.1451330299999967 23.7510081600000014, 97.0537220899999937
>> 40.5455008799999987, 105.2652701399999984 48.1330221300000005,
>> 100.9175268500000016 58.4333681499999997, 71.5608144800000048
>> 83.5511480100000057, 60.7118916800000008 86.2531609899999978,
>> 62.0046980799999972 75.1478175999999962, 83.1631000699999987
>> 42.8207167300000009, 92.8230586199999976 37.1917558199999974,
>> 95.9940112900000031 26.4705124599999984, 106.2205448200000006
>> 15.5197519199999991, 39.1451330299999967 23.7510081600000014))
> geos-devel mailing list
> geos-devel at lists.osgeo.org
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 2012.0.2197 / Virus Database: 2437/5254 - Release Date: 09/07/12
More information about the geos-devel