@@ -118,18 +118,18 @@ QgsRectangle QgsCircularStringV2::segmentBoundingBox( const QgsPointV2& pt1, con
118
118
QgsRectangle bbox ( pt1.x (), pt1.y (), pt1.x (), pt1.y () );
119
119
bbox.combineExtentWith ( pt3.x (), pt3.y () );
120
120
121
- QList<QgsPointV2> compassPoints = compassPointsOnSegment ( p1Angle, p2Angle, p3Angle, centerX, centerY, radius );
122
- QList<QgsPointV2> ::const_iterator cpIt = compassPoints.constBegin ();
121
+ QgsPointSequenceV2 compassPoints = compassPointsOnSegment ( p1Angle, p2Angle, p3Angle, centerX, centerY, radius );
122
+ QgsPointSequenceV2 ::const_iterator cpIt = compassPoints.constBegin ();
123
123
for ( ; cpIt != compassPoints.constEnd (); ++cpIt )
124
124
{
125
125
bbox.combineExtentWith ( cpIt->x (), cpIt->y () );
126
126
}
127
127
return bbox;
128
128
}
129
129
130
- QList<QgsPointV2> QgsCircularStringV2::compassPointsOnSegment ( double p1Angle, double p2Angle, double p3Angle, double centerX, double centerY, double radius )
130
+ QgsPointSequenceV2 QgsCircularStringV2::compassPointsOnSegment ( double p1Angle, double p2Angle, double p3Angle, double centerX, double centerY, double radius )
131
131
{
132
- QList<QgsPointV2> pointList;
132
+ QgsPointSequenceV2 pointList;
133
133
134
134
QgsPointV2 nPoint ( centerX, centerY + radius );
135
135
QgsPointV2 ePoint ( centerX + radius, centerY );
@@ -274,7 +274,7 @@ unsigned char* QgsCircularStringV2::asWkb( int& binarySize ) const
274
274
QgsWkbPtr wkb ( geomPtr, binarySize );
275
275
wkb << static_cast <char >( QgsApplication::endian () );
276
276
wkb << static_cast <quint32>( wkbType () );
277
- QList<QgsPointV2> pts;
277
+ QgsPointSequenceV2 pts;
278
278
points ( pts );
279
279
QgsGeometryUtils::pointsToWKB ( wkb, pts, is3D (), isMeasure () );
280
280
return geomPtr;
@@ -283,7 +283,7 @@ unsigned char* QgsCircularStringV2::asWkb( int& binarySize ) const
283
283
QString QgsCircularStringV2::asWkt ( int precision ) const
284
284
{
285
285
QString wkt = wktTypeStr () + ' ' ;
286
- QList<QgsPointV2> pts;
286
+ QgsPointSequenceV2 pts;
287
287
points ( pts );
288
288
wkt += QgsGeometryUtils::pointsToWKT ( pts, precision, is3D (), isMeasure () );
289
289
return wkt;
@@ -300,7 +300,7 @@ QDomElement QgsCircularStringV2::asGML2( QDomDocument& doc, int precision, const
300
300
301
301
QDomElement QgsCircularStringV2::asGML3 ( QDomDocument& doc, int precision, const QString& ns ) const
302
302
{
303
- QList<QgsPointV2> pts;
303
+ QgsPointSequenceV2 pts;
304
304
points ( pts );
305
305
306
306
QDomElement elemCurve = doc.createElementNS ( ns, " Curve" );
@@ -354,7 +354,7 @@ QgsPointV2 QgsCircularStringV2::endPoint() const
354
354
QgsLineStringV2* QgsCircularStringV2::curveToLine () const
355
355
{
356
356
QgsLineStringV2* line = new QgsLineStringV2 ();
357
- QList<QgsPointV2> points;
357
+ QgsPointSequenceV2 points;
358
358
int nPoints = numPoints ();
359
359
360
360
for ( int i = 0 ; i < ( nPoints - 2 ) ; i += 2 )
@@ -408,7 +408,7 @@ QgsPointV2 QgsCircularStringV2::pointN( int i ) const
408
408
return QgsPointV2 ( t, x, y, z, m );
409
409
}
410
410
411
- void QgsCircularStringV2::points ( QList<QgsPointV2>& pts ) const
411
+ void QgsCircularStringV2::points ( QgsPointSequenceV2 & pts ) const
412
412
{
413
413
pts.clear ();
414
414
int nPts = numPoints ();
@@ -418,7 +418,7 @@ void QgsCircularStringV2::points( QList<QgsPointV2>& pts ) const
418
418
}
419
419
}
420
420
421
- void QgsCircularStringV2::setPoints ( const QList<QgsPointV2>& points )
421
+ void QgsCircularStringV2::setPoints ( const QgsPointSequenceV2 & points )
422
422
{
423
423
clearCache ();
424
424
@@ -473,7 +473,7 @@ void QgsCircularStringV2::setPoints( const QList<QgsPointV2>& points )
473
473
}
474
474
}
475
475
476
- void QgsCircularStringV2::segmentize ( const QgsPointV2& p1, const QgsPointV2& p2, const QgsPointV2& p3, QList<QgsPointV2>& points ) const
476
+ void QgsCircularStringV2::segmentize ( const QgsPointV2& p1, const QgsPointV2& p2, const QgsPointV2& p3, QgsPointSequenceV2 & points ) const
477
477
{
478
478
// adapted code from postgis
479
479
double radius = 0 ;
@@ -670,7 +670,7 @@ void QgsCircularStringV2::addToPainterPath( QPainterPath& path ) const
670
670
671
671
for ( int i = 0 ; i < ( nPoints - 2 ) ; i += 2 )
672
672
{
673
- QList<QgsPointV2> pt;
673
+ QgsPointSequenceV2 pt;
674
674
segmentize ( QgsPointV2 ( mX [i], mY [i] ), QgsPointV2 ( mX [i + 1 ], mY [i + 1 ] ), QgsPointV2 ( mX [i + 2 ], mY [i + 2 ] ), pt );
675
675
for ( int j = 1 ; j < pt.size (); ++j )
676
676
{
0 commit comments