QRhiReadbackResult Struct

Describes the results of a potentially asynchronous buffer or texture readback operation. More...

Header: #include <QRhiReadbackResult>

Public Variables

int completed
QByteArray data
QRhiTexture::Format format
QSize pixelSize

Detailed Description

\inmoduleQtGui \since 6.6

When completed is set, the function is invoked when the data is available. format and pixelSize are set upon completion together with data.

Note: This is a RHI API with limited compatibility guarantees, see QRhi for details.

Member Variable Documentation

int QRhiReadbackResult::completed

Callback that is invoked upon completion, on the thread the QRhi operates on. Can be left set to nullptr, in which case no callback is invoked.

QByteArray QRhiReadbackResult::data

The buffer or image data.

See also QRhiResourceUpdateBatch::readBackTexture() and QRhiResourceUpdateBatch::readBackBuffer().

QRhiTexture::Format QRhiReadbackResult::format

Valid only for textures, the texture format.

QSize QRhiReadbackResult::pixelSize

Valid only for textures, the size in pixels.