QGIS API Documentation 3.41.0-Master (af5edcb665c)
|
Represents an overview renderer settings. More...
#include <qgsmeshsimplificationsettings.h>
Public Member Functions | |
bool | isEnabled () const |
Returns if the overview is active. | |
int | meshResolution () const |
Returns the mesh resolution i.e., the minimum size (average) of triangles in pixels. | |
void | readXml (const QDomElement &elem, const QgsReadWriteContext &context) |
Reads configuration from the given DOM element. | |
double | reductionFactor () const |
Returns the reduction factor used to build simplified mesh. | |
void | setEnabled (bool isEnabled) |
Sets if the overview is active. | |
void | setMeshResolution (int meshResolution) |
Sets the mesh resolution i.e., the minimum size (average) of triangles in pixels This value is used during map rendering to choose the most appropriate mesh from the list of simplified meshes. | |
void | setReductionFactor (double value) |
Sets the reduction factor used to build simplified mesh. | |
QDomElement | writeXml (QDomDocument &doc, const QgsReadWriteContext &context) const |
Writes configuration to a new DOM element. | |
Represents an overview renderer settings.
Definition at line 39 of file qgsmeshsimplificationsettings.h.
bool QgsMeshSimplificationSettings::isEnabled | ( | ) | const |
Returns if the overview is active.
Definition at line 20 of file qgsmeshsimplificationsettings.cpp.
int QgsMeshSimplificationSettings::meshResolution | ( | ) | const |
Returns the mesh resolution i.e., the minimum size (average) of triangles in pixels.
Definition at line 58 of file qgsmeshsimplificationsettings.cpp.
void QgsMeshSimplificationSettings::readXml | ( | const QDomElement & | elem, |
const QgsReadWriteContext & | context | ||
) |
Reads configuration from the given DOM element.
Definition at line 50 of file qgsmeshsimplificationsettings.cpp.
double QgsMeshSimplificationSettings::reductionFactor | ( | ) | const |
Returns the reduction factor used to build simplified mesh.
Definition at line 30 of file qgsmeshsimplificationsettings.cpp.
void QgsMeshSimplificationSettings::setEnabled | ( | bool | isEnabled | ) |
Sets if the overview is active.
Definition at line 25 of file qgsmeshsimplificationsettings.cpp.
void QgsMeshSimplificationSettings::setMeshResolution | ( | int | meshResolution | ) |
Sets the mesh resolution i.e., the minimum size (average) of triangles in pixels This value is used during map rendering to choose the most appropriate mesh from the list of simplified meshes.
The first mesh which has its average triangle size greater than this value will be chosen.
Definition at line 63 of file qgsmeshsimplificationsettings.cpp.
void QgsMeshSimplificationSettings::setReductionFactor | ( | double | value | ) |
Sets the reduction factor used to build simplified mesh.
The triangles count of the simplified mesh equals approximately the triangles count of base mesh divided by this factor. This reduction factor is used for simplification of each successive simplified mesh. For example, if the base mesh has 5M faces, and the reduction factor is 10, the first simplified mesh will have approximately 500 000 faces, the second 50 000 faces, the third 5000, ... If higher reduction factor leads to simpler meshes, it produces also fewer levels of detail. The reduction factor has to be strictly greater than 1. If not, the simplification processus will render nothing.
Definition at line 35 of file qgsmeshsimplificationsettings.cpp.
QDomElement QgsMeshSimplificationSettings::writeXml | ( | QDomDocument & | doc, |
const QgsReadWriteContext & | context | ||
) | const |
Writes configuration to a new DOM element.
Definition at line 40 of file qgsmeshsimplificationsettings.cpp.