QGIS API Documentation 3.40.0-Bratislava (b56115d8743)
|
Encapsulates the render context for a 2D point cloud rendering operation. More...
#include <qgspointcloudrenderer.h>
Classes | |
struct | TriangulationData |
Helper data structure used when rendering points as triangulated surface. More... | |
Public Member Functions | |
QgsPointCloudRenderContext (const QgsPointCloudRenderContext &rh)=delete | |
QgsPointCloudRenderContext (QgsRenderContext &context, const QgsVector3D &scale, const QgsVector3D &offset, double zValueScale, double zValueFixedOffset, QgsFeedback *feedback=nullptr) | |
Constructor for QgsPointCloudRenderContext. | |
QgsPointCloudAttributeCollection | attributes () const |
Returns the attributes associated with the rendered block. | |
QgsFeedback * | feedback () const |
Returns the feedback object used to cancel rendering. | |
void | incrementPointsRendered (long count) |
Increments the count of points rendered by the specified amount. | |
QgsVector3D | offset () const |
Returns the offset of the layer's int32 coordinates compared to CRS coords. | |
QgsPointCloudRenderContext & | operator= (const QgsPointCloudRenderContext &)=delete |
int | pointRecordSize () const |
Returns the size of a single point record. | |
long | pointsRendered () const |
Returns the total number of points rendered. | |
QgsRenderContext & | renderContext () |
Returns a reference to the context's render context. | |
const QgsRenderContext & | renderContext () const |
Returns a reference to the context's render context. | |
QgsVector3D | scale () const |
Returns the scale of the layer's int32 coordinates compared to CRS coords. | |
void | setAttributes (const QgsPointCloudAttributeCollection &attributes) |
Sets the attributes associated with the rendered block. | |
void | setOffset (const QgsVector3D &offset) |
Sets the offset of the layer's int32 coordinates compared to CRS coords. | |
void | setScale (const QgsVector3D &scale) |
Sets the scale of the layer's int32 coordinates compared to CRS coords. | |
TriangulationData & | triangulationData () |
Returns reference to the triangulation data structure (only used when rendering as triangles is enabled) | |
int | xOffset () const |
Returns the offset for the x value in a point record. | |
int | yOffset () const |
Returns the offset for the y value in a point record. | |
int | zOffset () const |
Returns the offset for the y value in a point record. | |
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. | |
Static Public Member Functions | |
template<typename T > | |
static void | getAttribute (const char *data, std::size_t offset, QgsPointCloudAttribute::DataType type, T &value) |
Retrieves the attribute value from data at the specified offset, where type indicates the original data type for the attribute. | |
Encapsulates the render context for a 2D point cloud rendering operation.
Definition at line 42 of file qgspointcloudrenderer.h.
QgsPointCloudRenderContext::QgsPointCloudRenderContext | ( | QgsRenderContext & | context, |
const QgsVector3D & | scale, | ||
const QgsVector3D & | offset, | ||
double | zValueScale, | ||
double | zValueFixedOffset, | ||
QgsFeedback * | feedback = nullptr |
||
) |
Constructor for QgsPointCloudRenderContext.
The scale and offset arguments specify the scale and offset of the layer's int32 coordinates compared to CRS coordinates respectively.
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 32 of file qgspointcloudrenderer.cpp.
|
delete |
|
inline |
Returns the attributes associated with the rendered block.
Definition at line 115 of file qgspointcloudrenderer.h.
|
inline |
Returns the feedback object used to cancel rendering.
Definition at line 172 of file qgspointcloudrenderer.h.
|
inlinestatic |
Retrieves the attribute value from data at the specified offset, where type indicates the original data type for the attribute.
Definition at line 181 of file qgspointcloudrenderer.h.
void QgsPointCloudRenderContext::incrementPointsRendered | ( | long | count | ) |
Increments the count of points rendered by the specified amount.
It is a point cloud renderer's responsibility to correctly call this after rendering a block of points.
Definition at line 48 of file qgspointcloudrenderer.cpp.
|
inline |
Returns the offset of the layer's int32 coordinates compared to CRS coords.
Definition at line 89 of file qgspointcloudrenderer.h.
|
delete |
|
inline |
Returns the size of a single point record.
Definition at line 127 of file qgspointcloudrenderer.h.
long QgsPointCloudRenderContext::pointsRendered | ( | ) | const |
Returns the total number of points rendered.
Definition at line 43 of file qgspointcloudrenderer.cpp.
|
inline |
Returns a reference to the context's render context.
Definition at line 67 of file qgspointcloudrenderer.h.
|
inline |
Returns a reference to the context's render context.
Definition at line 73 of file qgspointcloudrenderer.h.
|
inline |
Returns the scale of the layer's int32 coordinates compared to CRS coords.
Definition at line 78 of file qgspointcloudrenderer.h.
void QgsPointCloudRenderContext::setAttributes | ( | const QgsPointCloudAttributeCollection & | attributes | ) |
Sets the attributes associated with the rendered block.
Definition at line 53 of file qgspointcloudrenderer.cpp.
|
inline |
Sets the offset of the layer's int32 coordinates compared to CRS coords.
Definition at line 95 of file qgspointcloudrenderer.h.
|
inline |
Sets the scale of the layer's int32 coordinates compared to CRS coords.
Definition at line 84 of file qgspointcloudrenderer.h.
|
inline |
Returns reference to the triangulation data structure (only used when rendering as triangles is enabled)
Definition at line 244 of file qgspointcloudrenderer.h.
|
inline |
Returns the offset for the x value in a point record.
Definition at line 135 of file qgspointcloudrenderer.h.
|
inline |
Returns the offset for the y value in a point record.
Definition at line 143 of file qgspointcloudrenderer.h.
|
inline |
Returns the offset for the y value in a point record.
Definition at line 151 of file qgspointcloudrenderer.h.
|
inline |
Returns any constant offset which must be applied to z values taken from the point cloud index.
Definition at line 165 of file qgspointcloudrenderer.h.
|
inline |
Returns any constant scaling factor which must be applied to z values taken from the point cloud index.
Definition at line 158 of file qgspointcloudrenderer.h.