Qt3DRender::QRenderCaptureReply Class

class Qt3DRender::QRenderCaptureReply

接收渲染捕捉请求的结果。更多

头文件: #include <Qt3DRender/QRenderCaptureReply>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3drender)
target_link_libraries(mytarget PRIVATE Qt6::3drender)
qmake: QT += 3drender
在 QML 中: RenderCaptureReply
继承: QObject
状态:已废弃

属性

公共功能

int captureId() const
QImage image() const
bool isComplete() const
bool saveImage(const QString &fileName) const

信号

void completed()

详细说明

QRenderCapture::requestCapture 接收图像的对象。

属性文档

[read-only] captureId : const int

保存传递给 renderCapture 的 captureId。

访问功能:

int captureId() const

[read-only] complete : const bool

保存渲染捕捉的完整状态。

访问功能:

bool isComplete() const

通知信号:

void completed()

[read-only] image : const QImage

保存渲染捕捉后生成的图像。

访问函数:

QImage image() const

成员函数文档

[invokable] bool QRenderCaptureReply::saveImage(const QString &fileName) const

将渲染捕捉结果保存为图像,地址为fileName

如果图片保存成功,则返回 true;否则返回 false。

注: 可通过元对象系统和 QML 调用此函数。请参阅Q_INVOKABLE

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.