[geos-commits] r2464 - in trunk/source: geom headers/geos/geom
svn_geos at osgeo.org
svn_geos at osgeo.org
Mon May 4 19:04:13 EDT 2009
Author: strk
Date: 2009-05-04 19:04:13 -0400 (Mon, 04 May 2009)
New Revision: 2464
Modified:
trunk/source/geom/Geometry.cpp
trunk/source/headers/geos/geom/Geometry.h
trunk/source/headers/geos/geom/Geometry.inl
Log:
Bring Geometry port up a revision by having it use SnapIfNeededOp for overlay operations. Note that currently this doesn't affect the C-API nor the XMLTester codes, both using the BinaryOp original class (not JTS-ported) doing about the same thing as the SnapIfNeededOp class.
Modified: trunk/source/geom/Geometry.cpp
===================================================================
--- trunk/source/geom/Geometry.cpp 2009-05-04 22:03:12 UTC (rev 2463)
+++ trunk/source/geom/Geometry.cpp 2009-05-04 23:04:13 UTC (rev 2464)
@@ -4,6 +4,7 @@
* GEOS - Geometry Engine Open Source
* http://geos.refractions.net
*
+ * Copyright (C) 2009 Sandro Santilli <strk at keybit.net>
* Copyright (C) 2005-2006 Refractions Research Inc.
* Copyright (C) 2001-2002 Vivid Solutions Inc.
*
@@ -14,7 +15,7 @@
*
**********************************************************************
*
- * Last port: geom/Geometry.java rev. 1.105
+ * Last port: geom/Geometry.java rev. 1.106
*
**********************************************************************/
@@ -45,6 +46,7 @@
#include <geos/operation/relate/RelateOp.h>
#include <geos/operation/valid/IsValidOp.h>
#include <geos/operation/overlay/OverlayOp.h>
+#include <geos/operation/overlay/snap/SnapIfNeededOverlayOp.h>
#include <geos/operation/buffer/BufferOp.h>
#include <geos/operation/distance/DistanceOp.h>
#include <geos/operation/IsSimpleOp.h>
@@ -71,6 +73,7 @@
using namespace geos::operation::relate;
using namespace geos::operation::buffer;
using namespace geos::operation::overlay;
+using namespace geos::operation::overlay::snap;
using namespace geos::operation::distance;
using namespace geos::operation;
@@ -536,7 +539,7 @@
return getFactory()->createGeometryCollection();
}
- return OverlayOp::overlayOp(this, other, OverlayOp::opINTERSECTION);
+ return SnapIfNeededOverlayOp::overlayOp(*this, *other, OverlayOp::opINTERSECTION).release();
}
Geometry*
@@ -583,7 +586,7 @@
}
#endif
- return OverlayOp::overlayOp(this, other, OverlayOp::opUNION);
+ return SnapIfNeededOverlayOp::overlayOp(*this, *other, OverlayOp::opUNION).release();
}
Geometry*
@@ -594,7 +597,7 @@
if (isEmpty()) return getFactory()->createGeometryCollection();
if (other->isEmpty()) return clone();
- return OverlayOp::overlayOp(this, other, OverlayOp::opDIFFERENCE);
+ return SnapIfNeededOverlayOp::overlayOp(*this, *other, OverlayOp::opDIFFERENCE).release();
}
Geometry*
@@ -604,7 +607,7 @@
if ( isEmpty() ) return other->clone();
if ( other->isEmpty() ) return clone();
- return OverlayOp::overlayOp(this, other, OverlayOp::opSYMDIFFERENCE);
+ return SnapIfNeededOverlayOp::overlayOp(*this, *other, OverlayOp::opSYMDIFFERENCE).release();
}
int
Modified: trunk/source/headers/geos/geom/Geometry.h
===================================================================
--- trunk/source/headers/geos/geom/Geometry.h 2009-05-04 22:03:12 UTC (rev 2463)
+++ trunk/source/headers/geos/geom/Geometry.h 2009-05-04 23:04:13 UTC (rev 2464)
@@ -4,8 +4,9 @@
* GEOS - Geometry Engine Open Source
* http://geos.refractions.net
*
+ * Copyright (C) 2009 Sandro Santilli <strk at keybit.net>
+ * Copyright (C) 2005 2006 Refractions Research Inc.
* Copyright (C) 2001-2002 Vivid Solutions Inc.
- * Copyright (C) 2005 2006 Refractions Research Inc.
*
* This is free software; you can redistribute and/or modify it under
* the terms of the GNU Lesser General Public Licence as published
@@ -14,7 +15,7 @@
*
**********************************************************************
*
- * Last port: geom/Geometry.java rev. 1.105
+ * Last port: geom/Geometry.java rev. 1.106
*
**********************************************************************/
Modified: trunk/source/headers/geos/geom/Geometry.inl
===================================================================
--- trunk/source/headers/geos/geom/Geometry.inl 2009-05-04 22:03:12 UTC (rev 2463)
+++ trunk/source/headers/geos/geom/Geometry.inl 2009-05-04 23:04:13 UTC (rev 2464)
@@ -4,6 +4,7 @@
* GEOS - Geometry Engine Open Source
* http://geos.refractions.net
*
+ * Copyright (C) 2009 Sandro Santilli <strk at keybit.net>
* Copyright (C) 2005-2006 Refractions Research Inc.
*
* This is free software; you can redistribute and/or modify it under
@@ -13,7 +14,7 @@
*
**********************************************************************
*
- * Last port: geom/Geometry.java rev. 1.105
+ * Last port: geom/Geometry.java rev. 1.106
*
**********************************************************************/
More information about the geos-commits
mailing list