Class: QgsPointCloudRenderContext¶
- class qgis.core.QgsPointCloudRenderContext¶
Bases:
sip.wrapper
Encapsulates the render context for a 2D point cloud rendering operation.
New in version 3.18.
QgsPointCloudRenderContext(context:
QgsRenderContext
, scale:QgsVector3D
, offset:QgsVector3D
, zValueScale: float, zValueFixedOffset: float, feedback:QgsFeedback
= None) Constructor for QgsPointCloudRenderContext.The
scale
andoffset
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.Methods
Returns the attributes associated with the rendered block.
Returns the feedback object used to cancel rendering
Increments the count of points rendered by the specified amount.
Returns the offset of the layer's int32 coordinates compared to CRS coords.
Returns the size of a single point record.
Returns the total number of points rendered.
Returns a reference to the context's render context.
Returns the scale of the layer's int32 coordinates compared to CRS coords.
Sets the
attributes
associated with the rendered block.Sets the offset of the layer's int32 coordinates compared to CRS coords.
Sets the scale of the layer's int32 coordinates compared to CRS coords.
Returns the offset for the x value in a point record.
Returns the offset for the y value in a point record.
Returns the offset for the y value in a point record.
Returns any constant offset which must be applied to z values taken from the point cloud index.
Returns any constant scaling factor which must be applied to z values taken from the point cloud index.
- attributes(self) QgsPointCloudAttributeCollection ¶
Returns the attributes associated with the rendered block.
See also
- Return type
- feedback(self) QgsFeedback ¶
Returns the feedback object used to cancel rendering
New in version 3.20.
- Return type
- incrementPointsRendered(self, count: int)¶
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.
- Parameters
count (int) –
- offset(self) QgsVector3D ¶
Returns the offset of the layer’s int32 coordinates compared to CRS coords.
- Return type
- pointRecordSize(self) int ¶
Returns the size of a single point record.
- Return type
int
- pointsRendered(self) int ¶
Returns the total number of points rendered.
- Return type
int
- renderContext(self) QgsRenderContext ¶
Returns a reference to the context’s render context.
- Return type
- scale(self) QgsVector3D ¶
Returns the scale of the layer’s int32 coordinates compared to CRS coords.
- Return type
- setAttributes(self, attributes: QgsPointCloudAttributeCollection)¶
Sets the
attributes
associated with the rendered block.See also
- Parameters
attributes (QgsPointCloudAttributeCollection) –
- setOffset(self, offset: QgsVector3D)¶
Sets the offset of the layer’s int32 coordinates compared to CRS coords.
New in version 3.20.
- Parameters
offset (QgsVector3D) –
- setScale(self, scale: QgsVector3D)¶
Sets the scale of the layer’s int32 coordinates compared to CRS coords.
New in version 3.20.
- Parameters
scale (QgsVector3D) –
- xOffset(self) int ¶
Returns the offset for the x value in a point record.
See also
See also
- Return type
int
- yOffset(self) int ¶
Returns the offset for the y value in a point record.
See also
See also
- Return type
int
- zOffset(self) int ¶
Returns the offset for the y value in a point record.
See also
See also
- Return type
int
- zValueFixedOffset(self) float ¶
Returns any constant offset which must be applied to z values taken from the point cloud index.
Note
Scaling of z values via
zValueScale()
should be applied before thezValueFixedOffset()
.- Return type
float
- zValueScale(self) float ¶
Returns any constant scaling factor which must be applied to z values taken from the point cloud index.
Note
Scaling of z values should be applied before the
zValueFixedOffset()
.- Return type
float