RenderPassTexture QML Type
| Import Statement: | import QtQuick3D |
| Since: | Qt 6.11 |
| Inherits: |
属性
- format : enumeration
详细说明
RenderPassTexture 声明了一个离屏纹理,RenderPass 可以将其渲染到该纹理中。该纹理由渲染系统自动创建和管理。默认情况下,其大小会跟随View3D 视口的变化。
声明后,可通过 `ColorAttachment `(用于颜色输出)或 `DepthTextureAttachment `(用于深度输出)将该纹理附加到渲染通道上。随后,后续渲染通道或 `Texture ` 组件可通过 `RenderOutputProvider` 访问生成的纹理。
// Declare a float color buffer
RenderPassTexture {
id: hdrColorTexture
format: RenderPassTexture.RGBA16F
}
RenderPass {
commands: [
ColorAttachment {
name: "color0"
target: hdrColorTexture
}
]
}另请参阅 ColorAttachment 、DepthTextureAttachment 以及RenderOutputProvider 。
属性文档
format : enumeration
设置渲染目标纹理的格式。
可用格式包括:
| 常量 | 值 |
|---|---|
RenderPassTexture.Unknown | |
RenderPassTexture.RGBA8 | |
RenderPassTexture.RGBA16F | |
RenderPassTexture.RGBA32F | |
RenderPassTexture.R8 | |
RenderPassTexture.R16 | |
RenderPassTexture.R16F | |
RenderPassTexture.R32F | |
RenderPassTexture.Depth16 | |
RenderPassTexture.Depth24 | |
RenderPassTexture.Depth32 | |
RenderPassTexture.Depth24Stencil8 |
© 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.