18 #ifndef QGSGEOMETRYANALYZERH
19 #define QGSGEOMETRYANALYZERH
29 class QProgressDialog;
48 bool simplify(
QgsVectorLayer* layer,
const QString& shapefileName,
double tolerance,
49 bool onlySelectedFeatures =
false, QProgressDialog* p = 0 );
58 bool centroids(
QgsVectorLayer* layer,
const QString& shapefileName,
59 bool onlySelectedFeatures =
false, QProgressDialog* p = 0 );
67 bool extent(
QgsVectorLayer* layer,
const QString& shapefileName,
bool onlySelectedFeatures =
false, QProgressDialog* p = 0 );
78 bool buffer(
QgsVectorLayer* layer,
const QString& shapefileName,
double bufferDistance,
79 bool onlySelectedFeatures =
false,
bool dissolve =
false,
int bufferDistanceField = -1, QProgressDialog* p = 0 );
89 bool convexHull(
QgsVectorLayer* layer,
const QString& shapefileName,
bool onlySelectedFeatures =
false,
90 int uniqueIdField = -1, QProgressDialog* p = 0 );
100 bool dissolve(
QgsVectorLayer* layer,
const QString& shapefileName,
bool onlySelectedFeatures =
false,
101 int uniqueIdField = -1, QProgressDialog* p = 0 );
121 const QString& outputFormat,
int locationField1,
int locationField2 = -1,
int offsetField = -1,
double offsetScale = 1.0,
122 bool forceSingleGeometry =
false,
QgsVectorDataProvider* memoryProvider = 0, QProgressDialog* p = 0 );
132 QList<double> simpleMeasure(
QgsGeometry* geometry );
140 double bufferDistance,
int bufferDistanceField );
148 bool forceSingleType =
false );
154 QgsPoint createPointOffset(
double x,
double y,
double dist,
QgsGeometry* lineGeom )
const;
155 const unsigned char* locateBetweenWkbString(
const unsigned char* ptr,
QgsMultiPolyline& result,
double fromMeasure,
double toMeasure );
156 const unsigned char* locateAlongWkbString(
const unsigned char* ptr,
QgsMultiPoint& result,
double measure );
157 static bool clipSegmentByRange(
double x1,
double y1,
double m1,
double x2,
double y2,
double m2,
double range1,
double range2,
QgsPoint& pt1,
QgsPoint& pt2,
bool& secondPointClipped );
158 static void locateAlongSegment(
double x1,
double y1,
double m1,
double x2,
double y2,
double m2,
double measure,
bool& pt1Ok,
QgsPoint& pt1,
bool& pt2Ok,
QgsPoint& pt2 );
160 #endif //QGSVECTORANALYZER
QSet< QgsFeatureId > QgsFeatureIds
QList< QgsFeature > QgsFeatureList
A convenience class for writing vector files to disk.
The feature class encapsulates a single feature including its id, geometry and a list of field/values...
The QGis class provides vector geometry analysis functions.
QVector< QgsPoint > QgsMultiPoint
a collection of QgsPoints that share a common collection of attributes
A class to represent a point geometry.
QVector< QgsPolyline > QgsMultiPolyline
a collection of QgsPolylines that share a common collection of attributes
General purpose distance and area calculator.
This is the base class for vector data providers.
Represents a vector layer which manages a vector based data sets.