本页内容

Qt3DRender::QTextureImageDataGenerator Class

class Qt3DRender::QTextureImageDataGenerator

为QAbstractTextureImage 提供纹理图像数据。更多内容...

头文件: #include <qtextureimagedatagenerator.h>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3drender)
target_link_libraries(mytarget PRIVATE Qt6::3drender)
qmake: QT += 3drender
继承自: Qt3DCore::QAbstractFunctor
状态: 已弃用

该类已被废弃。我们强烈建议在新代码中不要使用它。

公共函数

virtual Qt3DRender::QTextureImageDataPtr operator()() = 0
virtual bool operator==(const Qt3DRender::QTextureImageDataGenerator &other) const = 0

详细说明

QTextureImageDataGenerator 是QAbstractTexture 的数据提供程序。QTextureImageDataGenerator 可用于扩展 Qt3D,提供更多加载纹理图像数据的方式,并支持用户自定义格式以及 Qt3D 本身不原生支持的格式。 数据由QTextureImageDataPtr 返回,其中包含将加载到纹理中的数据。QTextureImageDataGenerator由后端的Aspect任务执行。

成员函数文档

[pure virtual] Qt3DRender::QTextureImageDataPtr QTextureImageDataGenerator::operator()()

实现该方法,使其返回纹理图像数据。

[pure virtual] bool QTextureImageDataGenerator::operator==(const Qt3DRender::QTextureImageDataGenerator &other) const

实现该方法,将此纹理数据生成器与other 进行比较。返回一个布尔值,用于指示QAbstractTextureImage 是否需要重新加载QTextureImageData 。

相关的非成员

QTextureImageDataPtr

指向QTextureImageData 的共享指针。

© 2026 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.