class QHeightMapSurfaceDataProxy

Base proxy class for Q3DSurfaceWidgetItem . More

Inheritance diagram of PySide6.QtGraphs.QHeightMapSurfaceDataProxy

Synopsis

Properties

Methods

Signals

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

Detailed Description

QHeightMapSurfaceDataProxy takes care of the processing of height map data related to surfaces. It provides the visualization of a height map as a surface plot.

Since height maps do not contain values for X or Z axes, those values need to be given separately using the minXValue , maxXValue , minZValue , and maxZValue properties. The X-value corresponds to image horizontal direction and the Z-value to the vertical. Setting any of these properties triggers an asynchronous re-resolution of any existing height map.

See also

QSurfaceDataProxy Qt Graphs Data Handling with 3D

Note

Properties can be used directly when from __feature__ import true_property is used or via accessor functions otherwise.

property autoScaleYᅟ: bool

This property holds Scale height values to Y-axis..

Defaults to false.

When this property is set to true, the height values are scaled to fit on the Y-axis between minYValue and maxYValue .

See also

minYValue maxYValue

Access functions:
property heightMapᅟ: QImage

This property holds The height map image to be visualized..

Access functions:
property heightMapFileᅟ: str

This property holds The name of the file with a height map image to be visualized..

Access functions:
property maxXValueᅟ: float

This property holds The maximum X value for the generated surface points..

Defaults to 10.0.

When setting this property the corresponding minimum value is adjusted if necessary, to ensure that the range remains valid.

Access functions:
property maxYValueᅟ: float

This property holds The maximum Y value for the generated surface points..

Defaults to 10.0.

When setting this property the corresponding minimum value is adjusted if necessary, to ensure that the range remains valid.

See also

autoScaleY

Access functions:
property maxZValueᅟ: float

This property holds The maximum Z value for the generated surface points..

Defaults to 10.0.

When setting this property the corresponding minimum value is adjusted if necessary, to ensure that the range remains valid.

Access functions:
property minXValueᅟ: float

This property holds The minimum X value for the generated surface points..

Defaults to 0.0.

When setting this property the corresponding maximum value is adjusted if necessary, to ensure that the range remains valid.

Access functions:
property minYValueᅟ: float

This property holds The minimum Y value for the generated surface points..

Defaults to 0.0.

When setting this property the corresponding maximum value is adjusted if necessary, to ensure that the range remains valid.

See also

autoScaleY

Access functions:
property minZValueᅟ: float

This property holds The minimum Z value for the generated surface points..

Defaults to 0.0.

When setting this property the corresponding maximum value is adjusted if necessary, to ensure that the range remains valid.

Access functions:
__init__([parent=None])
Parameters:

parentQObject

Constructs QHeightMapSurfaceDataProxy with the given parent.

__init__(image[, parent=None])
Parameters:

Constructs QHeightMapSurfaceDataProxy with the given image and parent. Height map is set by calling setHeightMap() with image.

See also

heightMap

__init__(filename[, parent=None])
Parameters:
  • filename – str

  • parentQObject

Constructs QHeightMapSurfaceDataProxy from the given image filename and parent. Height map is set by calling setHeightMapFile() with filename.

See also

heightMapFile

autoScaleY()
Return type:

bool

See also

setAutoScaleY()

Getter of property autoScaleYᅟ .

autoScaleYChanged(enabled)
Parameters:

enabled – bool

Notification signal of property autoScaleYᅟ .

handlePendingResolve()
heightMap()
Return type:

QImage

See also

setHeightMap()

Getter of property heightMapᅟ .

heightMapChanged(image)
Parameters:

imageQImage

Notification signal of property heightMapᅟ .

heightMapFile()
Return type:

str

Getter of property heightMapFileᅟ .

heightMapFileChanged(filename)
Parameters:

filename – str

Notification signal of property heightMapFileᅟ .

maxXValue()
Return type:

float

See also

setMaxXValue()

Getter of property maxXValueᅟ .

maxXValueChanged(value)
Parameters:

value – float

Notification signal of property maxXValueᅟ .

maxYValue()
Return type:

float

See also

setMaxYValue()

Getter of property maxYValueᅟ .

maxYValueChanged(value)
Parameters:

value – float

Notification signal of property maxYValueᅟ .

maxZValue()
Return type:

float

See also

setMaxZValue()

Getter of property maxZValueᅟ .

maxZValueChanged(value)
Parameters:

value – float

Notification signal of property maxZValueᅟ .

minXValue()
Return type:

float

See also

setMinXValue()

Getter of property minXValueᅟ .

minXValueChanged(value)
Parameters:

value – float

Notification signal of property minXValueᅟ .

minYValue()
Return type:

float

See also

setMinYValue()

Getter of property minYValueᅟ .

minYValueChanged(value)
Parameters:

value – float

Notification signal of property minYValueᅟ .

minZValue()
Return type:

float

See also

setMinZValue()

Getter of property minZValueᅟ .

minZValueChanged(value)
Parameters:

value – float

Notification signal of property minZValueᅟ .

setAutoScaleY(enabled)
Parameters:

enabled – bool

See also

autoScaleY()

Setter of property autoScaleYᅟ .

setHeightMap(image)
Parameters:

imageQImage

Replaces current data with the height map data specified by image.

There are several formats the image can be given in, but if it is not in a directly usable format, a conversion is made.

Note

If the result seems wrong, the automatic conversion failed and you should try converting the image yourself before setting it. Preferred format is QImage::Format_RGB32 in grayscale.

The height of the image is read from the red component of the pixels if the image is in grayscale. Otherwise it is an average calculated from the red, green, and blue components of the pixels. Using grayscale images may improve data conversion speed for large images.

Not recommended formats: all mono formats (for example QImage::Format_Mono).

The height map is resolved asynchronously. arrayReset() is emitted when the data has been resolved.

See also

heightMap()

Setter of property heightMapᅟ .

setHeightMapFile(filename)
Parameters:

filename – str

Replaces current data with height map data from the file specified by filename.

Setter of property heightMapFileᅟ .

setMaxXValue(max)
Parameters:

max – float

See also

maxXValue()

Setter of property maxXValueᅟ .

setMaxYValue(max)
Parameters:

max – float

See also

maxYValue()

Setter of property maxYValueᅟ .

setMaxZValue(max)
Parameters:

max – float

See also

maxZValue()

Setter of property maxZValueᅟ .

setMinXValue(min)
Parameters:

min – float

See also

minXValue()

Setter of property minXValueᅟ .

setMinYValue(min)
Parameters:

min – float

See also

minYValue()

Setter of property minYValueᅟ .

setMinZValue(min)
Parameters:

min – float

See also

minZValue()

Setter of property minZValueᅟ .

setValueRanges(minX, maxX, minZ, maxZ)
Parameters:
  • minX – float

  • maxX – float

  • minZ – float

  • maxZ – float

A convenience function for setting all minimum (minX and minZ) and maximum (maxX and maxZ) values at the same time. The minimum values must be smaller than the corresponding maximum value. Otherwise the values get adjusted so that they are valid.