[geos-commits] [SCM] GEOS branch 3.11 updated. e183d2e0b459809efa5a7c315e1924411d8cbb4a

git at osgeo.org git at osgeo.org
Tue Nov 5 16:30:10 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, 3.11 has been updated
       via  e183d2e0b459809efa5a7c315e1924411d8cbb4a (commit)
       via  46d9a77d5deb8422bc0eda9bdce91357fbf1cd2f (commit)
      from  8067ef6d8a0117930aa6b70fc056aea033231250 (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 e183d2e0b459809efa5a7c315e1924411d8cbb4a
Author: Martin Davis <mtnclimb at gmail.com>
Date:   Tue Nov 5 16:29:46 2024 -0800

    Update NEWS

diff --git a/NEWS.md b/NEWS.md
index 3baf0b728..83ed37e03 100644
--- a/NEWS.md
+++ b/NEWS.md
@@ -9,6 +9,7 @@
   - Fix ConcaveHullOfPolygons nested shell handling (GH-1169, Martin Davis)
   - GEOSConcaveHullOfPolygons, avoid crash on zero-area input (GH-1071, Dan Baston)
   - MinimumClearance, avoid crash on NaN inputs (GH-1079, Dan Baston)
+  - Fix TopologyPreservingSimplifier/TaggedLineString to avoid jumping components (JTS-1096, Martin Davis)
 
 ## Changes in 3.11.4
 2024-06-05

commit 46d9a77d5deb8422bc0eda9bdce91357fbf1cd2f
Author: Martin Davis <mtnclimb at gmail.com>
Date:   Tue Nov 5 14:45:36 2024 -0800

    Fix TaggedLineString as per JTS 1096

diff --git a/src/simplify/TaggedLineString.cpp b/src/simplify/TaggedLineString.cpp
index c953217ff..469e1d2bf 100644
--- a/src/simplify/TaggedLineString.cpp
+++ b/src/simplify/TaggedLineString.cpp
@@ -169,7 +169,7 @@ TaggedLineString::extractCoordinates(
 
     if(size) {
         for(std::size_t i = 0; i < size; i++) {
-            TaggedLineSegment* seg = segs[i];
+                TaggedLineSegment* seg = segs[i];
             assert(seg);
             pts.push_back(seg->p0);
         }
@@ -186,7 +186,6 @@ TaggedLineString::extractCoordinates(
 const Coordinate&
 TaggedLineString::getCoordinate(std::size_t i) const
 {
-
     return parentLine->getCoordinateN(i);
 }
 
@@ -199,6 +198,10 @@ TaggedLineString::size() const
 const Coordinate&
 TaggedLineString::getComponentPoint() const
 {
+    //-- when simplified use a valid coordinate
+    if (resultSegs.size() > 0) {
+        return resultSegs[0]->p0;
+    }
     return getParentCoordinates()->getAt(1);
 }
 

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

Summary of changes:
 NEWS.md                           | 1 +
 src/simplify/TaggedLineString.cpp | 7 +++++--
 2 files changed, 6 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
GEOS


More information about the geos-commits mailing list