QGIS API Documentation
4.3.0-Master (52aa6503bed)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
analysis
mesh
qgsmeshcontours.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsmeshcontours.h
3
-----------------
4
begin : September 25th, 2019
5
copyright : (C) 2018 by Peter Petrik
6
email : zilolv at gmail dot com
7
***************************************************************************/
8
9
/***************************************************************************
10
* *
11
* This program is free software; you can redistribute it and/or modify *
12
* it under the terms of the GNU General Public License as published by *
13
* the Free Software Foundation; either version 2 of the License, or *
14
* (at your option) any later version. *
15
* *
16
***************************************************************************/
17
18
#ifndef QGSMESHCONTOURS_H
19
#define QGSMESHCONTOURS_H
20
21
#include <limits>
22
#include <memory>
23
24
#include "qgis_analysis.h"
25
#include "
qgis_sip.h
"
26
#include "
qgsfeature.h
"
27
#include "
qgsmeshdataprovider.h
"
28
#include "
qgsmeshrenderersettings.h
"
29
#include "
qgstriangularmesh.h
"
30
31
#include <QList>
32
#include <QMap>
33
#include <QPair>
34
#include <QString>
35
#include <QStringList>
36
#include <QVector>
37
38
class
QgsMeshLayer
;
39
class
QgsPoint
;
40
class
QgsGeometry
;
41
class
QgsFeedback
;
42
51
class
ANALYSIS_EXPORT
QgsMeshContours
52
{
53
public
:
59
QgsMeshContours
(
QgsMeshLayer
*layer );
60
74
QgsMeshContours
(
const
QgsTriangularMesh
&triangularMesh,
const
QgsMesh
&nativeMesh,
const
QVector<double> &datasetValues,
const
QgsMeshDataBlock
scalarActiveFaceFlagValues )
SIP_SKIP
;
75
76
77
~QgsMeshContours
();
78
89
QgsGeometry
exportLines
(
const
QgsMeshDatasetIndex
&index,
double
value,
QgsMeshRendererScalarSettings::DataResamplingMethod
method,
QgsFeedback
*feedback =
nullptr
);
90
101
QgsGeometry
exportLines
(
double
value,
QgsFeedback
*feedback =
nullptr
)
SIP_SKIP
;
102
114
QgsGeometry
exportPolygons
( const
QgsMeshDatasetIndex
&index,
double
min_value,
double
max_value,
QgsMeshRendererScalarSettings
::DataResamplingMethod method,
QgsFeedback
*feedback =
nullptr
);
115
127
QgsGeometry
exportPolygons
(
double
min_value,
double
max_value,
QgsFeedback
*feedback =
nullptr
)
SIP_SKIP
;
128
129
130
private:
131
void
populateCache( const
QgsMeshDatasetIndex
&index,
QgsMeshRendererScalarSettings
::DataResamplingMethod method );
132
133
QgsMeshLayer
*mMeshLayer =
nullptr
;
134
135
// cached values for particular index & interpolation method & layer
136
QgsMeshDatasetIndex
mCachedIndex;
137
QgsTriangularMesh
mTriangularMesh;
138
QgsMesh
mNativeMesh;
139
QVector<
double
> mDatasetValues;
140
QgsMeshDataBlock
mScalarActiveFaceFlagValues;
141
};
142
143
#endif
// QGSMESHCONTOURS_H
QgsFeedback
Base class for feedback objects to be used for cancellation of something running in a worker thread.
Definition
qgsfeedback.h:44
QgsGeometry
A geometry is the spatial representation of a feature.
Definition
qgsgeometry.h:267
QgsMeshContours::exportPolygons
QgsGeometry exportPolygons(const QgsMeshDatasetIndex &index, double min_value, double max_value, QgsMeshRendererScalarSettings::DataResamplingMethod method, QgsFeedback *feedback=nullptr)
Exports multi polygons representing the areas with values in range for particular dataset.
Definition
qgsmeshcontours.cpp:62
QgsMeshContours::exportLines
QgsGeometry exportLines(const QgsMeshDatasetIndex &index, double value, QgsMeshRendererScalarSettings::DataResamplingMethod method, QgsFeedback *feedback=nullptr)
Exports multi line string containing the contour line for particular dataset and value.
Definition
qgsmeshcontours.cpp:238
QgsMeshContours::~QgsMeshContours
~QgsMeshContours()
QgsMeshContours::QgsMeshContours
QgsMeshContours(QgsMeshLayer *layer)
Constructs the mesh contours exporter.
Definition
qgsmeshcontours.cpp:39
QgsMeshDataBlock
A block of integers/doubles from a mesh dataset.
Definition
qgsmeshdataset.h:142
QgsMeshDatasetIndex
An index that identifies the dataset group (e.g.
Definition
qgsmeshdataset.h:53
QgsMeshLayer
Represents a mesh layer supporting display of data on structured or unstructured meshes.
Definition
qgsmeshlayer.h:105
QgsMeshRendererScalarSettings
Represents a mesh renderer settings for scalar datasets.
Definition
qgsmeshrenderersettings.h:94
QgsMeshRendererScalarSettings::DataResamplingMethod
DataResamplingMethod
Resampling of value from dataset.
Definition
qgsmeshrenderersettings.h:104
QgsPoint
Point geometry type, with support for z-dimension and m-values.
Definition
qgspoint.h:53
QgsTriangularMesh
A triangular/derived mesh with vertices in map coordinates.
Definition
qgstriangularmesh.h:54
qgis_sip.h
SIP_SKIP
#define SIP_SKIP
Definition
qgis_sip.h:138
qgsfeature.h
qgsmeshdataprovider.h
qgsmeshrenderersettings.h
qgstriangularmesh.h
QgsMesh
Mesh - vertices, edges and faces.
Definition
qgsmeshdataprovider.h:53
Generated on
for QGIS API Documentation by
1.17.0