[postgis-users] Problems with GeomUnion
Bill Binko
bill at binko.net
Fri Apr 8 11:30:14 PDT 2005
On Fri, 8 Apr 2005, Martin Davis wrote:
> In JTS buffer is pretty tolerant of invalid topology. That's why I
> suggested using it to clean up bad geometry. AFAIK it should have
> similar behaviour under GEOS. It's not 100% guaranteed to work,
> however, so if there are failures some other approach might be needed
> for them.
>
> Fixing topology errors is usually not a simple single-step process - it
> can require some deviousness to deal with the infinite number of ways
> that geometry can be bad.
>
I'm learning that :(
One thing that would really help would be if there was a way to get
isvalid() to return why the geometry is invalid. It looks like the ones
that get a NOTICE: Self-Intersection can be fixed with buffer(), but those
that say things like:
NOTICE: IllegalArgumentException: points must form a closed linestring
NOTICE: IllegalArgumentException: points must form a closed linestring
NOTICE: IllegalArgumentException: geometries must not contain null elements
make buffer do ugly things.
I think the number of those is about 5% of my failures. I'd rather handle
those :)
I think I might be able to marry up stderr and stdout and get a list...
we'll see.
Bill
More information about the postgis-users
mailing list