QSSGRhiGraphicsPipelineState Class

空间场景图的图形管道状态。更多

Header: #include <QSSGRhiGraphicsPipelineState>
Since: Qt 6.7

公共类型

enum class Flag { DepthTestEnabled, DepthWriteEnabled, BlendEnabled, UsesStencilRef, UsesScissor }
flags Flags

公共变量

int colorAttachmentCount
QRhiGraphicsPipeline::CullMode cullMode
int depthBias
QRhiGraphicsPipeline::CompareOp depthFunc
float lineWidth
QRhiGraphicsPipeline::PolygonMode polygonMode
int samples
QRhiScissor scissor
float slopeScaledDepthBias
QRhiGraphicsPipeline::StencilOpState stencilOpFrontState
quint32 stencilRef
quint32 stencilWriteMask
std::array<QRhiGraphicsPipeline::TargetBlend, 8> targetBlend
QRhiViewport viewport

详细说明

该类是QtQuick3D 使用的方便类,用于封装来自QRhi 类(如QRhiGraphicsPipeline )的相关管道状态。因此,QSSGRhiGraphicsPipelineState 中使用的大多数类型和值都将直接映射到QRhi 中的相应类型或类。

成员类型文档

枚举类 QSSGRhiGraphicsPipelineState::Flag
flags QSSGRhiGraphicsPipelineState::Flags

常量
QSSGRhiGraphicsPipelineState::Flag::DepthTestEnabled0x1
QSSGRhiGraphicsPipelineState::Flag::DepthWriteEnabled0x2
QSSGRhiGraphicsPipelineState::Flag::BlendEnabled0x4
QSSGRhiGraphicsPipelineState::Flag::UsesStencilRef0x8
QSSGRhiGraphicsPipelineState::Flag::UsesScissor0x10

Flags 类型是QFlags<Flag> 的类型定义。它存储 Flag 值的 OR 组合。

成员变量文档

int QSSGRhiGraphicsPipelineState::colorAttachmentCount

颜色附件的数量。默认为 1。

另请参阅 QRhiTextureRenderTargetDescription::setColorAttachments() 和QRhiTextureRenderTargetDescription::colorAttachmentCount()。

QRhiGraphicsPipeline::CullMode QSSGRhiGraphicsPipelineState::cullMode

指定剔除模式。

另请参阅 QRhiGraphicsPipeline::CullMode

int QSSGRhiGraphicsPipelineState::depthBias

深度偏差。默认值为 0。

另请参阅 QRhiGraphicsPipeline::depthBias().

QRhiGraphicsPipeline::CompareOp QSSGRhiGraphicsPipelineState::depthFunc

深度比较功能。

另请参见 QRhiGraphicsPipeline::CompareOp

float QSSGRhiGraphicsPipelineState::lineWidth

使用的线宽。默认为 1.0

注: 对于 1.0 以外的值,要求在运行时报告支持特征QRhi::WideLines

QRhiGraphicsPipeline::PolygonMode QSSGRhiGraphicsPipelineState::polygonMode

多边形模式值。默认值为Fill

另请参阅 QRhiGraphicsPipeline::polygonMode() 。

int QSSGRhiGraphicsPipelineState::samples

采样计数。

注意: 采样计数为 1 表示无多重采样抗锯齿。

另请参阅 QRhiSwapChain::sampleCount().

QRhiScissor QSSGRhiGraphicsPipelineState::scissor

剪刀矩形。

注: 仅在设置UsesScissor 时使用。

另请参阅 QRhiCommandBuffer::setScissor().

float QSSGRhiGraphicsPipelineState::slopeScaledDepthBias

斜率缩放深度偏差。默认值为 0。

另请参阅 QRhiGraphicsPipeline::slopeScaledDepthBias().

QRhiGraphicsPipeline::StencilOpState QSSGRhiGraphicsPipelineState::stencilOpFrontState

描述钢网运行状态。

另请参阅 QRhiGraphicsPipeline::StencilOpState

quint32 QSSGRhiGraphicsPipelineState::stencilRef

活动模板参考值。

注: 仅在设置UsesStencilRef 时使用。

另请参阅 QRhiCommandBuffer::setStencilRef().

quint32 QSSGRhiGraphicsPipelineState::stencilWriteMask

模板写入掩码值。默认值为0xFF

另请参见 QRhiGraphicsPipeline::stencilWriteMask().

std::array<QRhiGraphicsPipeline::TargetBlend, 8> QSSGRhiGraphicsPipelineState::targetBlend

单色附件的混合状态。

另请参见 QRhiGraphicsPipeline::TargetBlend

QRhiViewport QSSGRhiGraphicsPipelineState::viewport

用于渲染的视口尺寸。

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