QSGDynamicTexture Class
QSGDynamicTexture 类是动态变化纹理(如渲染到 FBO 的内容)的基类。更多
头文件: | #include <QSGDynamicTexture> |
CMake.QSGDynamicTexture 类 | find_package(Qt6 REQUIRED COMPONENTS Quick) target_link_libraries(mytarget PRIVATE Qt6::Quick) |
qmake: | QT += quick |
继承: | QSGTexture |
公共函数
virtual bool | updateTexture() = 0 |
成员函数文档
[pure virtual]
bool QSGDynamicTexture::updateTexture()
调用此函数可明确更新动态纹理。
如果纹理因更新而发生变化,则函数返回 true;否则返回 false。
注意: 此函数通常在QQuickItem::updatePaintNode() 或QSGNode::preprocess() 中调用,即在场景图的synchronization
或node preprocessing
阶段调用。不鼓励在其他时间调用该函数,否则会导致意想不到的行为。
© 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.