-
Notifications
You must be signed in to change notification settings - Fork 442
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SimplifyDP produces wrong result for polygon at specific distance #498
Comments
The bug is caused by the fact that The QGIS output appears that it is using |
Not sure what the fix should be here. It's not easy to fix the buffer code. Ideally JTS should get a The problem can be avoided by using In fact, I think that the default behaviour for |
One thing I notice is that the |
Fixed by #655 |
Relevant parts: * Vastly improved overlay operations (intersection, union, etc). This will allow us to use JTS operations (currently using ESRI). + TopologicalExceptions have been mostly eliminated. + Performance is improved. For geometries that intersect in a small fraction of their area, performance is greatly improved. + More accurate in some cases. + https://locationtech.github.io/jts/javadoc/org/locationtech/jts/operation/overlayng/package-summary.html * Fix for `buffer` and `DouglasPeuckerSimplifier`: in some cases, the majority of the polygon would be dropped: + locationtech/jts#655 + locationtech/jts#498 * `WKBWriter` writes empty polygons in a fashion consistent with other libraries/tools. More details: https://github.com/locationtech/jts/releases/tag/jts-1.18.0
Relevant parts: * Vastly improved overlay operations (intersection, union, etc). This will allow us to use JTS operations (currently using ESRI). + TopologicalExceptions have been mostly eliminated. + Performance is improved. For geometries that intersect in a small fraction of their area, performance is greatly improved. + More accurate in some cases. + https://locationtech.github.io/jts/javadoc/org/locationtech/jts/operation/overlayng/package-summary.html * Fix for `buffer` and `DouglasPeuckerSimplifier`: in some cases, the majority of the polygon would be dropped: + locationtech/jts#655 + locationtech/jts#498 * `WKBWriter` writes empty polygons in a fashion consistent with other libraries/tools. More details: https://github.com/locationtech/jts/releases/tag/jts-1.18.0
As noted in GEOS 1004, the following polygon produces a VERY incorrect result for simplify tolerance = 0.0036.
Interestingly, using tolerance = 0.00365 produces a reasonable result.
Input:
JTS simplifyDP with tolerance = 0.0036 produces following incorrect output:
The expected output is more like this (produced from QGIS):
The text was updated successfully, but these errors were encountered: