QBlendEquationArguments Class

class Qt3DRender::QBlendEquationArguments

Encapsulates blending information: specifies how the incoming values (what's going to be drawn) are going to affect the existing values (what is already drawn). More...

Header: #include <QBlendEquationArguments>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3drender)
target_link_libraries(mytarget PRIVATE Qt6::3drender)
qmake: QT += 3drender
In QML: BlendEquationArguments
Inherits: Qt3DRender::QRenderState
Status: Deprecated

Public Types

enum Blending { Zero, One, SourceColor, SourceAlpha, Source1Alpha, …, OneMinusSource1Color0 }

Properties

Public Functions

QBlendEquationArguments(Qt3DCore::QNode *parent = nullptr)
int bufferIndex() const
Qt3DRender::QBlendEquationArguments::Blending destinationAlpha() const
Qt3DRender::QBlendEquationArguments::Blending destinationRgb() const
Qt3DRender::QBlendEquationArguments::Blending sourceAlpha() const
Qt3DRender::QBlendEquationArguments::Blending sourceRgb() const

Public Slots

void setBufferIndex(int index)
void setDestinationAlpha(Qt3DRender::QBlendEquationArguments::Blending destinationAlpha)
void setDestinationRgb(Qt3DRender::QBlendEquationArguments::Blending destinationRgb)
void setDestinationRgba(Qt3DRender::QBlendEquationArguments::Blending destinationRgba)
void setSourceAlpha(Qt3DRender::QBlendEquationArguments::Blending sourceAlpha)
void setSourceRgb(Qt3DRender::QBlendEquationArguments::Blending sourceRgb)
void setSourceRgba(Qt3DRender::QBlendEquationArguments::Blending sourceRgba)

Signals

void bufferIndexChanged(int index)
void destinationAlphaChanged(Qt3DRender::QBlendEquationArguments::Blending destinationAlpha)
void destinationRgbChanged(Qt3DRender::QBlendEquationArguments::Blending destinationRgb)
void destinationRgbaChanged(Qt3DRender::QBlendEquationArguments::Blending destinationRgba)
void sourceAlphaChanged(Qt3DRender::QBlendEquationArguments::Blending sourceAlpha)
void sourceRgbChanged(Qt3DRender::QBlendEquationArguments::Blending sourceRgb)
void sourceRgbaChanged(Qt3DRender::QBlendEquationArguments::Blending sourceRgba)

Detailed Description

OpenGL pre-3.0: Set the same blend state for all draw buffers (one QBlendEquationArguments) OpenGL 3.0-pre4.0: Set the same blend state for all draw buffers, but can disable blending for particular buffers (one QBlendEquationArguments for setting glBlendFunc, n QBlendEquationArgumentss for enabling/disabling Draw Buffers) OpenGL 4.0+: Can set blend state individually for each draw buffer.

Member Type Documentation

enum QBlendEquationArguments::Blending

ConstantValueDescription
Qt3DRender::QBlendEquationArguments::Zero0GL_ZERO
Qt3DRender::QBlendEquationArguments::One1GL_ONE
Qt3DRender::QBlendEquationArguments::SourceColor0x0300GL_SRC_COLOR
Qt3DRender::QBlendEquationArguments::SourceAlpha0x0302GL_SRC_ALPHA
Qt3DRender::QBlendEquationArguments::Source1Alpha0x303GL_SRC1_ALPHA
Qt3DRender::QBlendEquationArguments::Source1Color0x304GL_SRC1_COLOR
Qt3DRender::QBlendEquationArguments::DestinationColor0x0306GL_DST_COLOR
Qt3DRender::QBlendEquationArguments::DestinationAlpha0x0304GL_DST_ALPHA
Qt3DRender::QBlendEquationArguments::SourceAlphaSaturate0x0308GL_SRC_ALPHA_SATURATE
Qt3DRender::QBlendEquationArguments::ConstantColor0x80010GL_CONSTANT_COLOR
Qt3DRender::QBlendEquationArguments::ConstantAlpha0x8003GL_CONSTANT_ALPHA
Qt3DRender::QBlendEquationArguments::OneMinusSourceColor0x0301GL_ONE_MINUS_SRC_COLOR
Qt3DRender::QBlendEquationArguments::OneMinusSourceAlpha0x0303GL_ONE_MINUS_SRC_ALPHA
Qt3DRender::QBlendEquationArguments::OneMinusDestinationAlpha0x0305GL_ONE_MINUS_DST_ALPHA
Qt3DRender::QBlendEquationArguments::OneMinusDestinationColor0x0307GL_ONE_MINUS_DST_COLOR
Qt3DRender::QBlendEquationArguments::OneMinusConstantColor0x8002GL_ONE_MINUS_CONSTANT_COLOR
Qt3DRender::QBlendEquationArguments::OneMinusConstantAlpha0x8004GL_ONE_MINUS_CONSTANT_ALPHA
Qt3DRender::QBlendEquationArguments::OneMinusSource1Alpha0x8005GL_ONE_MINUS_SRC1_ALPHA
Qt3DRender::QBlendEquationArguments::OneMinusSource1Color0x8006GL_ONE_MINUS_SRC1_COLOR
Qt3DRender::QBlendEquationArguments::OneMinusSource1Color0OneMinusSource1ColorGL_ONE_MINUS_SRC1_COLOR (deprecated)

Property Documentation

bufferIndex : int

Specifies the index of the Draw Buffer that this BlendEquationArguments applies to. If negative, this will apply to all Draw Buffers.

Access functions:

int bufferIndex() const
void setBufferIndex(int index)

Notifier signal:

void bufferIndexChanged(int index)

destinationAlpha : Blending

Access functions:

Qt3DRender::QBlendEquationArguments::Blending destinationAlpha() const
void setDestinationAlpha(Qt3DRender::QBlendEquationArguments::Blending destinationAlpha)

Notifier signal:

void destinationAlphaChanged(Qt3DRender::QBlendEquationArguments::Blending destinationAlpha)

destinationRgb : Blending

Access functions:

Qt3DRender::QBlendEquationArguments::Blending destinationRgb() const
void setDestinationRgb(Qt3DRender::QBlendEquationArguments::Blending destinationRgb)

Notifier signal:

void destinationRgbChanged(Qt3DRender::QBlendEquationArguments::Blending destinationRgb)

sourceAlpha : Blending

Access functions:

Qt3DRender::QBlendEquationArguments::Blending sourceAlpha() const
void setSourceAlpha(Qt3DRender::QBlendEquationArguments::Blending sourceAlpha)

Notifier signal:

void sourceAlphaChanged(Qt3DRender::QBlendEquationArguments::Blending sourceAlpha)

sourceRgb : Blending

Access functions:

Qt3DRender::QBlendEquationArguments::Blending sourceRgb() const
void setSourceRgb(Qt3DRender::QBlendEquationArguments::Blending sourceRgb)

Notifier signal:

void sourceRgbChanged(Qt3DRender::QBlendEquationArguments::Blending sourceRgb)

Member Function Documentation

[explicit] QBlendEquationArguments::QBlendEquationArguments(Qt3DCore::QNode *parent = nullptr)

The constructor creates a new blend state object with the specified parent.

[signal] void QBlendEquationArguments::destinationRgbaChanged(Qt3DRender::QBlendEquationArguments::Blending destinationRgba)

Notify that both destinationRgb and destinationAlpha properties have changed to destinationRgba.

[slot] void QBlendEquationArguments::setDestinationRgba(Qt3DRender::QBlendEquationArguments::Blending destinationRgba)

Change both destinationRgb and destinationAlpha properties to destinationRgba.

[slot] void QBlendEquationArguments::setSourceRgba(Qt3DRender::QBlendEquationArguments::Blending sourceRgba)

Change both sourceRgb and sourceAlpha properties to sourceRgba.

[signal] void QBlendEquationArguments::sourceRgbaChanged(Qt3DRender::QBlendEquationArguments::Blending sourceRgba)

Notify that both sourceRgb and sourceAlpha properties have changed to sourceRgba.