[geos-devel] Union of linestrings

Sandro Santilli strk at keybit.net
Tue Mar 1 07:06:00 PST 2016


On Tue, Mar 01, 2016 at 03:41:37PM +0100, Mateusz Loskot wrote:
> On 1 March 2016 at 15:09, Sandro Santilli <strk at keybit.net> wrote:
> > On Tue, Mar 01, 2016 at 02:52:32PM +0100, Mateusz Loskot wrote:
> >
> >> What about constructing a single LineString from connected
> >> segments, instead of a MultiLineString?
> >
> > LineMerge operation, aka GEOSLineMerge_r in C-API.
> 
> Right, makes sense.
> 
> So, by design, union of connected segments always yields MultiLineString.
> Safe assumption?

I think this is the current case, yes.

The union operation makes no effort to drop nodes of degree 2 
(having just 2 edges connected) from the built topology.

--strk;


More information about the geos-devel mailing list