VkBlendFactor - Framebuffer blending factors
Description
The semantics of the enum values are described in the table below:
| RGB Blend Factors (Sr,Sg,Sb) or (Dr,Dg,Db) | Alpha Blend Factor (Sa or Da) |
|---|---|---|
(0,0,0) | 0 | |
(1,1,1) | 1 | |
(Rs0,Gs0,Bs0) | As0 | |
(1-Rs0,1-Gs0,1-Bs0) | 1-As0 | |
(Rd,Gd,Bd) | Ad | |
(1-Rd,1-Gd,1-Bd) | 1-Ad | |
(As0,As0,As0) | As0 | |
(1-As0,1-As0,1-As0) | 1-As0 | |
(Ad,Ad,Ad) | Ad | |
(1-Ad,1-Ad,1-Ad) | 1-Ad | |
(Rc,Gc,Bc) | Ac | |
(1-Rc,1-Gc,1-Bc) | 1-Ac | |
(Ac,Ac,Ac) | Ac | |
(1-Ac,1-Ac,1-Ac) | 1-Ac | |
BLEND_FACTOR_SRC_ALPHA_SATURATE
| (f,f,f); f = min(As0,1-Ad) | 1 |
(Rs1,Gs1,Bs1) | As1 | |
(1-Rs1,1-Gs1,1-Bs1) | 1-As1 | |
(As1,As1,As1) | As1 | |
(1-As1,1-As1,1-As1) | 1-As1 |
Blend Factors
In this table, the following conventions are used:
Rs0,Gs0,Bs0 and As0 represent the first source color R, G, B, and A components, respectively, for the fragment output location corresponding to the color attachment being blended.
Rs1,Gs1,Bs1 and As1 represent the second source color R, G, B, and A components, respectively, used in dual source blending modes, for the fragment output location corresponding to the color attachment being blended.
Rd,Gd,Bd and Ad represent the R, G, B, and A components of the destination color. That is, the color currently in the corresponding color attachment for this fragment/sample.
Rc,Gc,Bc and Ac represent the blend constant R, G, B, and A components, respectively.
See Also
VK_VERSION_1_0, ColorBlendEquationEXT, PipelineColorBlendAttachmentState
Constructors
Instances6Eq, Ord, Read, Show, Storable, Zero
Eq BlendFactorDefined in vulkan-3.27 · Vulkan.Core10.Enums.BlendFactorOrd BlendFactorDefined in vulkan-3.27 · Vulkan.Core10.Enums.BlendFactorRead BlendFactorDefined in vulkan-3.27 · Vulkan.Core10.Enums.BlendFactorShow BlendFactorDefined in vulkan-3.27 · Vulkan.Core10.Enums.BlendFactorStorable BlendFactorDefined in vulkan-3.27 · Vulkan.Core10.Enums.BlendFactorZero BlendFactorDefined in vulkan-3.27 · Vulkan.Core10.Enums.BlendFactor