QGIS API Documentation 3.28.0-Firenze (ed3ad0430f)
|
Sigma averages over the values between 0 (bed level) and 1 (surface). More...
#include <qgsmesh3daveraging.h>
Public Member Functions | |
QgsMeshSigmaAveragingMethod () | |
Constructs the sigma method for whole value range 0-1. More... | |
QgsMeshSigmaAveragingMethod (double startFraction, double endFraction) | |
Constructs the sigma method. More... | |
~QgsMeshSigmaAveragingMethod () override | |
QgsMesh3dAveragingMethod * | clone () const override |
Clone the instance. More... | |
double | endFraction () const |
Returns ending fraction. More... | |
bool | equals (const QgsMesh3dAveragingMethod *other) const override |
Returns whether method equals to other. More... | |
void | readXml (const QDomElement &elem) override |
Reads configuration from the given DOM element. More... | |
double | startFraction () const |
Returns starting fraction. More... | |
QDomElement | writeXml (QDomDocument &doc) const override |
Writes configuration to a new DOM element. More... | |
Public Member Functions inherited from QgsMesh3dAveragingMethod | |
QgsMesh3dAveragingMethod (Method method) | |
Ctor. More... | |
virtual | ~QgsMesh3dAveragingMethod ()=default |
Dtor. More... | |
QgsMeshDataBlock | calculate (const QgsMesh3dDataBlock &block3d, QgsFeedback *feedback=nullptr) const |
Calculated 2d block values from 3d stacked mesh values. More... | |
virtual QgsMesh3dAveragingMethod * | clone () const =0 |
Clone the instance. More... | |
virtual bool | equals (const QgsMesh3dAveragingMethod *other) const =0 |
Returns whether method equals to other. More... | |
Method | method () const |
Returns type of averaging method. More... | |
virtual void | readXml (const QDomElement &elem)=0 |
Reads configuration from the given DOM element. More... | |
virtual QDomElement | writeXml (QDomDocument &doc) const =0 |
Writes configuration to a new DOM element. More... | |
Additional Inherited Members | |
Public Types inherited from QgsMesh3dAveragingMethod | |
enum | Method { MultiLevelsAveragingMethod = 0 , SigmaAveragingMethod , RelativeHeightAveragingMethod , ElevationAveragingMethod } |
Type of averaging method. More... | |
Static Public Member Functions inherited from QgsMesh3dAveragingMethod | |
static QgsMesh3dAveragingMethod * | createFromXml (const QDomElement &elem) |
Creates the instance from XML by calling readXml of derived classes. More... | |
static bool | equals (const QgsMesh3dAveragingMethod *a, const QgsMesh3dAveragingMethod *b) |
Returns whether two methods equal. More... | |
Sigma averages over the values between 0 (bed level) and 1 (surface).
The fractions will be truncated to 0-1. For example: the average of between a quarter and 3 quarters of the water column - Sigma from 0.25 to 0.75
Definition at line 240 of file qgsmesh3daveraging.h.
QgsMeshSigmaAveragingMethod::QgsMeshSigmaAveragingMethod | ( | ) |
Constructs the sigma method for whole value range 0-1.
Definition at line 381 of file qgsmesh3daveraging.cpp.
QgsMeshSigmaAveragingMethod::QgsMeshSigmaAveragingMethod | ( | double | startFraction, |
double | endFraction | ||
) |
Constructs the sigma method.
startFraction | starting fraction (0-1) |
endFraction | ending fraction, must be higher or equal than startFraction (0-1) |
Definition at line 386 of file qgsmesh3daveraging.cpp.
|
overridedefault |
|
overridevirtual |
Clone the instance.
Implements QgsMesh3dAveragingMethod.
Definition at line 431 of file qgsmesh3daveraging.cpp.
double QgsMeshSigmaAveragingMethod::endFraction | ( | ) | const |
Returns ending fraction.
In range 0-1, where 1 means the surface level and 0 bed level. Always higher or equal than startFraction()
Definition at line 441 of file qgsmesh3daveraging.cpp.
|
overridevirtual |
Returns whether method equals to other.
Implements QgsMesh3dAveragingMethod.
Definition at line 421 of file qgsmesh3daveraging.cpp.
|
overridevirtual |
Reads configuration from the given DOM element.
Implements QgsMesh3dAveragingMethod.
Definition at line 407 of file qgsmesh3daveraging.cpp.
double QgsMeshSigmaAveragingMethod::startFraction | ( | ) | const |
Returns starting fraction.
In range 0-1, where 1 means the surface level and 0 bed level. Always lower or equal than endFraction()
Definition at line 436 of file qgsmesh3daveraging.cpp.
|
overridevirtual |
Writes configuration to a new DOM element.
Implements QgsMesh3dAveragingMethod.
Definition at line 399 of file qgsmesh3daveraging.cpp.