Merging linear overlay results?
Sandro Santilli
strk at kbt.io
Thu May 21 04:05:05 PDT 2026
Just to add that PostGIS Topology also does the post-overlay linemerge:
https://gitea.osgeo.org/postgis/postgis/src/branch/master/liblwgeom/topo/lwgeom_topo.c#L7520-L7534
Allowing to request such behavior earlier would help performances there too,
I'm in favour of such addition
--strk;
On Wed, May 20, 2026 at 09:22:45AM -0400, Daniel Baston wrote:
> Hi,
>
> I've noticed that the GEOS overlay code has the capability to merge linear
> output geometries, using LineBuilder::addResultLinesMerged. However, this
> capability has never been enabled. GEOS clients ([1], [2]) sometimes end up
> calling GEOSLineMerge as a follow-up step to overlay, but this is
> inefficient and cumbersome. (Among other things, GEOSLineMerge silently
> drops any non-linear inputs.)
>
> Does it make sense to consider enabling this behavior? It would be helpful
> for reconstructing CompoundCurves, which have no way to retain their
> complex parentage information through the noding journey. I guess we would
> need a GEOSUnionWithParams, GEOSIntersectionWithParams, etc...
>
> Dan
>
> [1]
> https://github.com/qgis/QGIS/blob/b298119a5b09ae3903596ec2ffaf8aaff7ba78a3/src/core/geometry/qgsgeos.cpp#L1985
> [2]
> https://github.com/OSGeo/gdal/blob/ad495515b681bfb5f660f5de17e9ef1c2c8f153f/apps/gdalalg_vector_dissolve.cpp#L134
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/geos-devel/attachments/20260521/7724216f/attachment.sig>
More information about the geos-devel
mailing list