Skip to content
Permalink
Browse files

Function name without get, changed more function calls to use numberO…

…fGeometries()

git-svn-id: http://svn.osgeo.org/qgis/trunk@9713 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent
mhugent committed Nov 27, 2008
1 parent 52c76d5 commit 59f4b3fa1d2dec69d37d6c9d4babff8ecc55e24b
Showing with 6 additions and 6 deletions.
  1. +5 −5 src/core/qgsgeometry.cpp
  2. +1 −1 src/core/qgsgeometry.h
@@ -4832,7 +4832,7 @@ int QgsGeometry::splitPolygonGeometry( GEOSGeometry* splitLine, QList<QgsGeometr
GEOSGeometry *cutEdges = GEOSPolygonizer_getCutEdges( &nodedGeometry, 1 );
if ( cutEdges )
{
if ( GEOSGetNumGeometries( cutEdges ) > 0 )
if ( numberOfGeometries( cutEdges ) > 0 )
{
GEOSGeom_destroy( cutEdges );
GEOSGeom_destroy( nodedGeometry );
@@ -4844,7 +4844,7 @@ int QgsGeometry::splitPolygonGeometry( GEOSGeometry* splitLine, QList<QgsGeometr
#endif

GEOSGeometry *polygons = GEOSPolygonize( &nodedGeometry, 1 );
if ( !polygons || GEOSGetNumGeometries( polygons ) == 0 )
if ( !polygons || numberOfGeometries( polygons ) == 0 )
{
if ( polygons )
GEOSGeom_destroy( polygons );
@@ -4864,7 +4864,7 @@ int QgsGeometry::splitPolygonGeometry( GEOSGeometry* splitLine, QList<QgsGeometr
//ratio intersect geometry / geometry. This should be close to 1
//if the polygon belongs to the input geometry

for ( int i = 0; i < getNumberOfGeometries( polygons ); i++ )
for ( int i = 0; i < numberOfGeometries( polygons ); i++ )
{
const GEOSGeometry *polygon = GEOSGetGeometryN( polygons, i );
intersectGeometry = GEOSIntersection( mGeos, polygon );
@@ -4883,7 +4883,7 @@ int QgsGeometry::splitPolygonGeometry( GEOSGeometry* splitLine, QList<QgsGeometr
}

bool splitDone = true;
int nGeometriesThis = getNumberOfGeometries( mGeos ); //original number of geometries
int nGeometriesThis = numberOfGeometries( mGeos ); //original number of geometries
if ( testedGeometries.size() == nGeometriesThis )
{
splitDone = false;
@@ -5003,7 +5003,7 @@ GEOSGeometry *QgsGeometry::nodeGeometries( const GEOSGeometry *splitLine, GEOSGe
return unionGeometry;
}

int QgsGeometry::getNumberOfGeometries(GEOSGeometry* g) const
int QgsGeometry::numberOfGeometries(GEOSGeometry* g) const
{
if(!g)
{
@@ -418,7 +418,7 @@ class CORE_EXPORT QgsGeometry
GEOSGeometry* nodeGeometries( const GEOSGeometry *splitLine, GEOSGeometry *poly ) const;

/**Returns number of single geometry in a geos geometry. Is save for geos 2 and 3*/
int getNumberOfGeometries(GEOSGeometry* g) const;
int numberOfGeometries(GEOSGeometry* g) const;

int mergeGeometriesMultiTypeSplit( QVector<GEOSGeometry*>& splitResult );

0 comments on commit 59f4b3f

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