Class: QgsPointCloudRenderContext

class qgis.core.QgsPointCloudRenderContext(context: QgsRenderContext, scale: QgsVector3D, offset: QgsVector3D, zValueScale: float, zValueFixedOffset: float)

Bases: sip.wrapper

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.

Encapsulates the render context for a 2D point cloud rendering operation.

Methods

attributes

Returns the attributes associated with the rendered block.

incrementPointsRendered

Increments the count of points rendered by the specified amount.

offset

Returns the offset of the layer’s int32 coordinates compared to CRS coords.

pointRecordSize

Returns the size of a single point record.

pointsRendered

Returns the total number of points rendered.

renderContext

Returns a reference to the context’s render context.

scale

Returns the scale of the layer’s int32 coordinates compared to CRS coords.

setAttributes

Sets the attributes associated with the rendered block.

xOffset

Returns the offset for the x value in a point record.

yOffset

Returns the offset for the y value in a point record.

zOffset

Returns the offset for the y value in a point record.

zValueFixedOffset

Returns any constant offset which must be applied to z values taken from the point cloud index.

zValueScale

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

setAttributes()

Return type

QgsPointCloudAttributeCollection

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

QgsVector3D

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

QgsRenderContext

scale(self)QgsVector3D

Returns the scale of the layer’s int32 coordinates compared to CRS coords.

Return type

QgsVector3D

setAttributes(self, attributes: QgsPointCloudAttributeCollection)

Sets the attributes associated with the rendered block.

See also

attributes()

Parameters

attributes (QgsPointCloudAttributeCollection) –

xOffset(self)int

Returns the offset for the x value in a point record.

See also

yOffset()

See also

zOffset()

Return type

int

yOffset(self)int

Returns the offset for the y value in a point record.

See also

xOffset()

See also

zOffset()

Return type

int

zOffset(self)int

Returns the offset for the y value in a point record.

See also

xOffset()

See also

yOffset()

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 the zValueFixedOffset().

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