[geos-commits] [SCM] GEOS branch main updated. 0a8fc37a965bd29d61d14249ba22a2ae66fd58fa

git at osgeo.org git at osgeo.org
Mon Feb 26 02:19:53 PST 2024


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GEOS".

The branch, main has been updated
       via  0a8fc37a965bd29d61d14249ba22a2ae66fd58fa (commit)
      from  7273a963fe438f218bafdc1b26540c7efebb328f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 0a8fc37a965bd29d61d14249ba22a2ae66fd58fa
Author: Mike Taves <mwtoews at gmail.com>
Date:   Mon Feb 26 20:24:06 2024 +1300

    Regression test for mitre buffer that previously made an invalid geometry

diff --git a/tests/unit/operation/buffer/BufferParametersTest.cpp b/tests/unit/operation/buffer/BufferParametersTest.cpp
index a05bc4f38..91343ae74 100644
--- a/tests/unit/operation/buffer/BufferParametersTest.cpp
+++ b/tests/unit/operation/buffer/BufferParametersTest.cpp
@@ -367,8 +367,21 @@ void object::test<22>()
         "POLYGON ((-4.14213562373095 -10, -10 -4.14213562373095, -10 104.14213562373095, -4.14213562373095 110, 104.14213562373095 110, 110 104.14213562373095, 110 -4.142135623730951, 104.14213562373095 -10, -4.14213562373095 -10))");
 }
 
+// Buffer produces invalid output
+// https://github.com/libgeos/geos/issues/856
+template<>
+template<>
+void object::test<23>()
+{
+    auto geom = _reader.read("POLYGON ((-23.989123360549296 73.1287474328027, -22.537997105552297 94.06368412079055,-18.796973600895146 93.80437130274495,-17.80121237894408 108.16990157009043,-21.542235883601226 108.42921438813606,-20.967403753721864 116.7221345967023,-4.728530705460814 116.7221568196225,-7.82790182044367 72.00851605865441,-23.989123360549296 73.1287474328027))");
 
+    BufferParameters bp;
+    bp.setJoinStyle(BufferParameters::JOIN_MITRE);
+    BufferOp op(geom.get(), bp);
 
+    auto result = op.getResultGeometry(10);
+    ensure(result->isValid());
+}
 
 
 } // namespace tut

-----------------------------------------------------------------------

Summary of changes:
 tests/unit/operation/buffer/BufferParametersTest.cpp | 13 +++++++++++++
 1 file changed, 13 insertions(+)


hooks/post-receive
-- 
GEOS


More information about the geos-commits mailing list