Comments (4)
Yes, agreed, this should be warned about in the doc at a minimum.
Better yet would be a check to see if a non-empty input produced an empty output, and throw an exception.
from jts.
Or even better, doing some magic fixing :-)
I am in the same boat as everybody else in having a geometry fixer which is "good enough for my purpose, but not good enough as a general solution" (based on polygonizing the noded linestrings and - and this is where it can fall down - guessing holes).
Is there some clever way of leveraging the knowledge that the original input geometry was valid in this case, or do we always end up in the "you can't really say what an invalid geometry should actually be" situation?
from jts.
The use of buffer(0) in the GeometryPrecisionReducer is a hack. It should be possible to always produce a valid precision-reduced geometry. Essentially this requires repolygonizing with knowledge about whether edges are from shells or holes (so that an appropriate decision can be made about building holes and merging hole or shell edges if needed. There is code that already does this in the JTS overlay module, but it's not built in a reusable way.
from jts.
Fixed by #648
from jts.
Related Issues (20)
- "Unable to find a convex corner" in ConstrainedDelaunayTriangulator HOT 1
- IncrementalDelaunayTriangulator needs logic to handle frame
- Single-side offset provides triangular spikes near sharp turns HOT 1
- Negative buffer operation leaves some collinear points (regression from 1.19.0)
- Single-side buffering closes shape only sometimes HOT 2
- NullPointerException thrown by SimpleNoder when geometry covers but does not overlap HOT 1
- How to take distance transfrom to meters?UTM'unit is meters? HOT 1
- parseKMLCoordinatesAndAttributes can fail
- BufferInputLineSimplifier doesn't simplify end segments of rings
- CoordinateArraySequence.getCoordinate is hard to understand HOT 1
- AppSweep identifies Medium security vulnerability: HTTP URLs to opengis were found HOT 2
- PolygonTriangulator fails to find a convex corner on provided valid geometry HOT 4
- Trying to use GeoServer and it seems the error comes back to Coordinate.setM HOT 1
- ConstrainedDelaunayTriangulator causes an IllegalStateException: Unable to find a convex corner HOT 3
- Buffer with Flat endcap produces artifacts
- Calculating difference and intersection between two polygons is resulting in a polygon having incorrect shape HOT 1
- Expose GeometryOverlay `isOverlayNG` flag
- Non-closed polygon parsing caused unexpected Exception HOT 1
- Abnormal result with BufferOp.getResultGeometry() method
- Incorrect Voronoi diagram generated for 4 points HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jts.