QGIS API Documentation 3.39.0-Master (3783037d301)
|
Encapsulates the render context for a 3D point cloud rendering operation. More...
#include <qgspointcloudlayer3drenderer.h>
Public Member Functions | |
QgsPointCloud3DRenderContext (const Qgs3DRenderContext &context, const QgsCoordinateTransform &coordinateTransform, std::unique_ptr< QgsPointCloud3DSymbol > symbol, double zValueScale, double zValueFixedOffset) | |
Constructor for QgsPointCloud3DRenderContext. | |
QgsPointCloud3DRenderContext (const QgsPointCloud3DRenderContext &rh)=delete | |
QgsPointCloudAttributeCollection | attributes () const |
Returns the attributes associated with the rendered block. | |
void | cancelRendering () const |
Cancels rendering. | |
QgsCoordinateTransform | coordinateTransform () const |
Returns the coordinate transform used to transform points from layer CRS to the map CRS. | |
QgsFeedback * | feedback () const |
Returns the feedback object used to cancel rendering and check if rendering was canceled. | |
template<typename T > | |
void | getAttribute (const char *data, std::size_t offset, QgsPointCloudAttribute::DataType type, T &value) const |
Retrieves the attribute value from data at the specified offset, where type indicates the original data type for the attribute. | |
QSet< int > | getFilteredOutValues () const |
Returns a set containing the filtered out values. | |
bool | isCanceled () const |
Returns true if the rendering is canceled. | |
QgsRectangle | layerExtent () const |
Returns the 3D scene's extent in layer crs. | |
QgsPointCloud3DRenderContext & | operator= (const QgsPointCloud3DRenderContext &)=delete |
void | setAttributes (const QgsPointCloudAttributeCollection &attributes) |
Sets the attributes associated with the rendered block. | |
void | setCoordinateTransform (const QgsCoordinateTransform &coordinateTransform) |
Sets the coordinate transform used to transform points from layer CRS to the map CRS. | |
void | setFilteredOutCategories (const QgsPointCloudCategoryList &categories) |
Sets the list of categories of the classification that won't be rendered. | |
void | setSymbol (QgsPointCloud3DSymbol *symbol) |
Sets the symbol used for rendering the point cloud Takes ownership over the passed symbol. | |
QgsPointCloud3DSymbol * | symbol () const |
Returns the symbol used for rendering the point cloud. | |
double | zValueFixedOffset () const |
Returns any constant offset which must be applied to z values taken from the point cloud index. | |
double | zValueScale () const |
Returns any constant scaling factor which must be applied to z values taken from the point cloud index. | |
Public Member Functions inherited from Qgs3DRenderContext | |
Qgs3DRenderContext ()=default | |
QgsCoordinateReferenceSystem | crs () const |
Returns the coordinate reference system used in the 3D scene. | |
QgsExpressionContext & | expressionContext () |
Gets the expression context. | |
const QgsExpressionContext & | expressionContext () const |
Gets the expression context (const version). | |
QgsRectangle | extent () const |
Returns the 3D scene's 2D extent in the 3D scene's CRS. | |
float | fieldOfView () const |
Returns the camera lens' field of view. | |
QgsVector3D | mapToWorldCoordinates (const QgsVector3D &mapCoords) const |
Converts map coordinates to 3D world coordinates (applies offset and turns (x,y,z) into (x,-z,y)). | |
QgsVector3D | origin () const |
Returns coordinates in map CRS at which 3D scene has origin (0,0,0) | |
double | outputDpi () const |
Returns DPI used for conversion between real world units (e.g. | |
QColor | selectionColor () const |
Returns color used for selected features. | |
void | setExpressionContext (const QgsExpressionContext &context) |
Sets the expression context. | |
const QgsDateTimeRange & | temporalRange () const |
Returns the temporal range for the map. | |
QgsTerrainGenerator * | terrainGenerator () const |
Returns the terrain generator. | |
bool | terrainRenderingEnabled () const |
Returns whether the 2D terrain surface will be rendered. | |
double | terrainVerticalScale () const |
Returns vertical scale (exaggeration) of terrain. | |
QgsCoordinateTransformContext | transformContext () const |
Returns the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system. | |
QgsVector3D | worldToMapCoordinates (const QgsVector3D &worldCoords) const |
Converts 3D world coordinates to map coordinates (applies offset and turns (x,y,z) into (x,-z,y)). | |
Additional Inherited Members | |
Static Public Member Functions inherited from Qgs3DRenderContext | |
static Qgs3DRenderContext | fromMapSettings (const Qgs3DMapSettings *mapSettings) |
Creates an initialized Qgs3DRenderContext instance from given Qgs3DMapSettings. | |
Encapsulates the render context for a 3D point cloud rendering operation.
Definition at line 41 of file qgspointcloudlayer3drenderer.h.
QgsPointCloud3DRenderContext::QgsPointCloud3DRenderContext | ( | const Qgs3DRenderContext & | context, |
const QgsCoordinateTransform & | coordinateTransform, | ||
std::unique_ptr< QgsPointCloud3DSymbol > | symbol, | ||
double | zValueScale, | ||
double | zValueFixedOffset | ||
) |
Constructor for QgsPointCloud3DRenderContext.
The zValueScale argument specifies any constant scaling factor which must be applied to z values taken from the point cloud index.
The zValueFixedOffset argument specifies any constant offset value which must be added to z values taken from the point cloud index.
Definition at line 29 of file qgspointcloudlayer3drenderer.cpp.
|
delete |
|
inline |
Returns the attributes associated with the rendered block.
Definition at line 65 of file qgspointcloudlayer3drenderer.h.
void QgsPointCloud3DRenderContext::cancelRendering | ( | ) | const |
Cancels rendering.
Definition at line 74 of file qgspointcloudlayer3drenderer.cpp.
|
inline |
Returns the coordinate transform used to transform points from layer CRS to the map CRS.
Definition at line 181 of file qgspointcloudlayer3drenderer.h.
|
inline |
Returns the feedback object used to cancel rendering and check if rendering was canceled.
Definition at line 186 of file qgspointcloudlayer3drenderer.h.
|
inline |
Retrieves the attribute value from data at the specified offset, where type indicates the original data type for the attribute.
Definition at line 105 of file qgspointcloudlayer3drenderer.h.
QSet< int > QgsPointCloud3DRenderContext::getFilteredOutValues | ( | ) | const |
Returns a set containing the filtered out values.
Definition at line 55 of file qgspointcloudlayer3drenderer.cpp.
bool QgsPointCloud3DRenderContext::isCanceled | ( | ) | const |
Returns true
if the rendering is canceled.
Definition at line 69 of file qgspointcloudlayer3drenderer.cpp.
|
inline |
Returns the 3D scene's extent in layer crs.
Definition at line 192 of file qgspointcloudlayer3drenderer.h.
|
delete |
void QgsPointCloud3DRenderContext::setAttributes | ( | const QgsPointCloudAttributeCollection & | attributes | ) |
Sets the attributes associated with the rendered block.
Definition at line 40 of file qgspointcloudlayer3drenderer.cpp.
void QgsPointCloud3DRenderContext::setCoordinateTransform | ( | const QgsCoordinateTransform & | coordinateTransform | ) |
Sets the coordinate transform used to transform points from layer CRS to the map CRS.
Definition at line 63 of file qgspointcloudlayer3drenderer.cpp.
void QgsPointCloud3DRenderContext::setFilteredOutCategories | ( | const QgsPointCloudCategoryList & | categories | ) |
Sets the list of categories of the classification that won't be rendered.
Definition at line 50 of file qgspointcloudlayer3drenderer.cpp.
void QgsPointCloud3DRenderContext::setSymbol | ( | QgsPointCloud3DSymbol * | symbol | ) |
Sets the symbol used for rendering the point cloud Takes ownership over the passed symbol.
Definition at line 45 of file qgspointcloudlayer3drenderer.cpp.
|
inline |
Returns the symbol used for rendering the point cloud.
Definition at line 79 of file qgspointcloudlayer3drenderer.h.
|
inline |
Returns any constant offset which must be applied to z values taken from the point cloud index.
Definition at line 160 of file qgspointcloudlayer3drenderer.h.
|
inline |
Returns any constant scaling factor which must be applied to z values taken from the point cloud index.
Definition at line 153 of file qgspointcloudlayer3drenderer.h.