[geos-devel] GEOS NG Regression Review (GDAL feedback)

Martin Davis mtnclimb at gmail.com
Thu Sep 17 08:50:16 PDT 2020


Thanks for testing, Even.

Interestingly, in JTS the test case you give below for
OverlayNG.intersection actually returns the same result as the old code:

MULTILINESTRING ((833978.557030887 0, 835092.849076364 0),
(832864.275023695 0, 833978.556808034 0))

So this is something to look into on the GEOS side.

On Thu, Sep 17, 2020 at 4:39 AM Even Rouault <even.rouault at spatialys.com>
wrote:

>
>
>
> The intersection of the input geometry with this multipolygon of 2 parts
> can be shown with:
>
>
>
> from osgeo import ogr
>
>
>
> # input geometry crossing the antimeridian (UTM 60N)
>
> geom = ogr.CreateGeometryFromWkt('LINESTRING(832864.275023695
> 0,835092.849076364 0)')
>
>
>
> # multipolygon with one part left to the antimeridian, one part right
>
> geom2 = ogr.CreateGeometryFromWkt('MULTIPOLYGON (((832864.275023695
> 0.0,833978.556808034 -0.000110682755987,833978.556808034
> 0.0,833978.556808034 0.000110682755987,832864.275023695
> 0.0,832864.275023695 0.0)),((835092.849076364 0.0,833978.557030887
> -0.000110682755987,833978.557030887 0.0,833978.557030887
> 0.000110682755987,835092.849076364 0.0,835092.849076364 0.0)))')
>
>
>
> # intersection
>
> print(geom.Intersection(geom2))
>
>
>
> With OverlayNG, the following leads to a LINESTRING EMPTY, whereas with
> GEOS 3.8something, it leads to the expected result of
>
> MULTILINESTRING ((832864.275023695 0.0,833978.556808034
> 0.0),(833978.557030887 0.0,835092.849076364 0.0))
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geos-devel/attachments/20200917/0b67a004/attachment.html>


More information about the geos-devel mailing list