Rory,
My original PolygonRectifier work was based handling on a fairly
specific set of errors, so it sounds like it probably wouldn't handle
the spectrum of issues that you're encountering.
Building a strategy chain based on a set of heuristic processes sounds
like a great idea. I can imagine that this could get a bit complex,
since different kinds of errors would have to be addressed in different
ways, and the sequence of handling them could be critical. The
PolygonRectifier code would fit into this as one possible heuristic.
For the specific problems you mention (invalid or collapsed holes) this
might not be too hard to do - it should suffice to clean each hole ring
separately, and then recombine them and run a final rectification. Is
repeated points really an issue? If so, this should be trivial to clean.
So what are your next steps - cut code? Or are you looking for someone
to do this for you?
Martin
Rory Plaire wrote:
Greetings,
Martin, in the talk "Secrets of JTS" you did at the 2007 FOSS4G, you
mentioned a "PolygonRectifier" to fill in for dealing with problematic
polygons. I'm interested in something like this myself, since many
polygons I encounter are invalid in many and colorful ways, often so
bad as to not even allow a Buffer(0.0) to handle them (invalid holes,
collapsed holes, repeated points, etc.). I'd like to somehow collect a
set of heuristics for dealing with these in some sort of class,
maybe like a configurable strategy chain, which is responsible for
handling them before they are subsequently passed to Buffer(0.0) for
generating a pristine, valid polygon. Have you (or anyone) elaborated
any further on "PolygonRectifier" or something like it?
thanks,
-rory
------------------------------------------------------------------------
_______________________________________________
jts-devel mailing list
[email protected]
http://lists.refractions.net/mailman/listinfo/jts-devel
--
Martin Davis
Senior Technical Architect
Refractions Research, Inc.
(250) 383-3022
_______________________________________________
jts-devel mailing list
[email protected]
http://lists.refractions.net/mailman/listinfo/jts-devel