[geos-devel] Union of linestrings

Sandro Santilli strk at keybit.net
Mon Feb 29 11:10:52 PST 2016


On Mon, Feb 29, 2016 at 07:18:08PM +0100, Mateusz Loskot wrote:
> Hi,
> 
> I've started adding tests for OverlayOp [1] and I noticed
> curious results for basic test case.
> 
> OverlayOp(UNION) on Four segments of a sqare
> always construct a MultiLineString.
> I'd have expected a polygon, shouldn't I?

No, you shouldn't.
The union of lines do not yeld an area.
You can use the Polygonizer class to build polygons
from linework.

--strk;

  ()   Free GIS & Flash consultant/developer
  /\   http://strk.keybit.net/services.html


More information about the geos-devel mailing list