[geos-commits] [SCM] GEOS branch master updated. e6ffc18a8de531f487088e7275a0af9d1d6736bc

git at osgeo.org git at osgeo.org
Mon Aug 17 13:10:59 PDT 2020


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, master has been updated
       via  e6ffc18a8de531f487088e7275a0af9d1d6736bc (commit)
       via  16512c007ecc29780e53c58271bb9143f5bf37d0 (commit)
      from  264168eeb0f921f0edfc9acab6f12ee5357a15ae (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 e6ffc18a8de531f487088e7275a0af9d1d6736bc
Author: Sandro Santilli <strk at kbt.io>
Date:   Mon Aug 17 22:05:30 2020 +0200

    [OverlayNG] Fix handling of LinearRing
    
    Closes #1043

diff --git a/src/operation/overlayng/EdgeNodingBuilder.cpp b/src/operation/overlayng/EdgeNodingBuilder.cpp
index c925dc7..725cc32 100644
--- a/src/operation/overlayng/EdgeNodingBuilder.cpp
+++ b/src/operation/overlayng/EdgeNodingBuilder.cpp
@@ -156,13 +156,13 @@ EdgeNodingBuilder::add(const Geometry* g, int geomIndex)
         case GEOS_POLYGON:
             return addPolygon(static_cast<const Polygon*>(g), geomIndex);
         case GEOS_LINESTRING:
+        case GEOS_LINEARRING:
             return addLine(static_cast<const LineString*>(g), geomIndex);
         case GEOS_MULTILINESTRING:
         case GEOS_MULTIPOLYGON:
         case GEOS_GEOMETRYCOLLECTION:
             return addCollection(static_cast<const GeometryCollection*>(g), geomIndex);
         case GEOS_POINT:
-        case GEOS_LINEARRING:
         case GEOS_MULTIPOINT:
             return; // do nothing
         default:

commit 16512c007ecc29780e53c58271bb9143f5bf37d0
Author: Sandro Santilli <strk at kbt.io>
Date:   Mon Aug 17 22:04:38 2020 +0200

    Add debugging lines (default to off)

diff --git a/src/operation/overlayng/OverlayGraph.cpp b/src/operation/overlayng/OverlayGraph.cpp
index d381bcf..2033c19 100644
--- a/src/operation/overlayng/OverlayGraph.cpp
+++ b/src/operation/overlayng/OverlayGraph.cpp
@@ -18,6 +18,10 @@
 #include <geos/geom/Coordinate.h>
 #include <geos/geom/CoordinateSequence.h>
 
+#ifndef GEOS_DEBUG
+#define GEOS_DEBUG 0
+#endif
+
 namespace geos {      // geos
 namespace operation { // geos.operation
 namespace overlayng { // geos.operation.overlayng
@@ -80,6 +84,9 @@ OverlayGraph::addEdge(Edge* edge)
     // CoordinateSequence* pts = = edge->getCoordinates().release();
     CoordinateSequence* pts = edge->releaseCoordinates();
     OverlayEdge* e = createEdgePair(pts, createOverlayLabel(edge));
+#if GEOS_DEBUG
+    std::cerr << "added edge: " << *e << std::endl;
+#endif
     insert(e);
     insert(e->symOE());
     return e;
diff --git a/src/operation/overlayng/OverlayNG.cpp b/src/operation/overlayng/OverlayNG.cpp
index 961be62..dbcae1b 100644
--- a/src/operation/overlayng/OverlayNG.cpp
+++ b/src/operation/overlayng/OverlayNG.cpp
@@ -32,6 +32,11 @@
 
 #include <algorithm>
 
+
+#ifndef GEOS_DEBUG
+#define GEOS_DEBUG 0
+#endif
+
 namespace geos {      // geos
 namespace operation { // geos.operation
 namespace overlayng { // geos.operation.overlayng
@@ -220,6 +225,11 @@ OverlayNG::labelGraph(OverlayGraph* graph)
 std::unique_ptr<Geometry>
 OverlayNG::extractResult(int p_opCode, OverlayGraph* graph)
 {
+
+#if GEOS_DEBUG
+    std::cerr << "OverlayNG::extractResult: graph: " << *graph << std::endl;
+#endif
+
     //--- Build polygons
     std::vector<OverlayEdge*> resultAreaEdges = graph->getResultAreaEdges();
     PolygonBuilder polyBuilder(resultAreaEdges, geomFact);

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

Summary of changes:
 src/operation/overlayng/EdgeNodingBuilder.cpp |  2 +-
 src/operation/overlayng/OverlayGraph.cpp      |  7 +++++++
 src/operation/overlayng/OverlayNG.cpp         | 10 ++++++++++
 3 files changed, 18 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
GEOS


More information about the geos-commits mailing list