Skip to content
Permalink
Browse files

Fix for reshape problem with closed lines

git-svn-id: http://svn.osgeo.org/qgis/trunk@11807 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent
mhugent committed Oct 15, 2009
1 parent 6a00570 commit adeffe82d87e4903e992fa0d97e9b576adeb4bda
Showing with 6 additions and 7 deletions.
  1. +6 −7 src/core/qgsgeometry.cpp
@@ -5181,13 +5181,6 @@ GEOSGeometry* QgsGeometry::reshapeLine( const GEOSGeometry* line, const GEOSGeom
return 0;
}


bool isRing = false;
if ( GEOSGeomTypeId( line ) == GEOS_LINEARRING )
{
isRing = true;
}

//begin and end point of original line
const GEOSCoordSequence* lineCoordSeq = GEOSGeom_getCoordSeq( line );
if ( !lineCoordSeq )
@@ -5212,6 +5205,12 @@ GEOSGeometry* QgsGeometry::reshapeLine( const GEOSGeometry* line, const GEOSGeom
GEOSGeometry* beginLineVertex = createGeosPoint( QgsPoint( x1, y1 ) );
GEOSGeometry* endLineVertex = createGeosPoint( QgsPoint( x2, y2 ) );

bool isRing = false;
if ( GEOSGeomTypeId( line ) == GEOS_LINEARRING || GEOSEquals( beginLineVertex, endLineVertex ) == 1 )
{
isRing = true;
}

//node line and reshape line
GEOSGeometry* nodedGeometry = nodeGeometries( reshapeLineGeos, line );
if ( !nodedGeometry )

0 comments on commit adeffe8

Please sign in to comment.
You can’t perform that action at this time.