Ticket #922 (closed enhancement: fixed)
Have ST_Union aggregate use UnaryUnion from GEOS-3.0.0
| Reported by: | strk | Owned by: | pramsey |
|---|---|---|---|
| Priority: | medium | Milestone: | PostGIS 2.0.0 |
| Component: | postgis | Version: | trunk |
| Keywords: | Cc: |
Description
Current code of PostGIS uses GEOSUnionCascaded only for polygons, and that's even correct because the GEOS C-API GEOSUnionCascade would throw an exception if anything but (multi)Polygons are given.
Instead the new GEOSUnaryUnion interface from GEOS-3.0.0 accepts any kind of geometry. Internally uses Cascaded union for polygons but also does special handling of points and lines. See http://trac.osgeo.org/geos/ticket/392 for an example case in which the UnaryUnion? works whereas normal union doesn't.
Always using UnaryUnion? when build against GEOS-3.3.0 would then simplify the code and improve union robustness.
