vulkan-3.26.1: Bindings to the Vulkan graphics API.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Vulkan.Core10.Enums.BlendFactor

Synopsis

Documentation

newtype BlendFactor Source #

VkBlendFactor - Framebuffer blending factors

Description

The semantics of the enum values are described in the table below:

BlendFactor RGB Blend Factors (Sr,Sg,Sb) or (Dr,Dg,Db) Alpha Blend Factor (Sa or Da)
BLEND_FACTOR_ZERO(0,0,0)0
BLEND_FACTOR_ONE(1,1,1)1
BLEND_FACTOR_SRC_COLOR(Rs0,Gs0,Bs0)As0
BLEND_FACTOR_ONE_MINUS_SRC_COLOR(1-Rs0,1-Gs0,1-Bs0)1-As0
BLEND_FACTOR_DST_COLOR(Rd,Gd,Bd)Ad
BLEND_FACTOR_ONE_MINUS_DST_COLOR(1-Rd,1-Gd,1-Bd)1-Ad
BLEND_FACTOR_SRC_ALPHA(As0,As0,As0)As0
BLEND_FACTOR_ONE_MINUS_SRC_ALPHA(1-As0,1-As0,1-As0)1-As0
BLEND_FACTOR_DST_ALPHA(Ad,Ad,Ad)Ad
BLEND_FACTOR_ONE_MINUS_DST_ALPHA(1-Ad,1-Ad,1-Ad)1-Ad
BLEND_FACTOR_CONSTANT_COLOR(Rc,Gc,Bc)Ac
BLEND_FACTOR_ONE_MINUS_CONSTANT_COLOR(1-Rc,1-Gc,1-Bc)1-Ac
BLEND_FACTOR_CONSTANT_ALPHA(Ac,Ac,Ac)Ac
BLEND_FACTOR_ONE_MINUS_CONSTANT_ALPHA(1-Ac,1-Ac,1-Ac)1-Ac
BLEND_FACTOR_SRC_ALPHA_SATURATE (f,f,f); f = min(As0,1-Ad)1
BLEND_FACTOR_SRC1_COLOR(Rs1,Gs1,Bs1)As1
BLEND_FACTOR_ONE_MINUS_SRC1_COLOR(1-Rs1,1-Gs1,1-Bs1)1-As1
BLEND_FACTOR_SRC1_ALPHA(As1,As1,As1)As1
BLEND_FACTOR_ONE_MINUS_SRC1_ALPHA(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

BlendFactor Int32 

Instances

Instances details
Storable BlendFactor Source # 
Instance details

Defined in Vulkan.Core10.Enums.BlendFactor

Read BlendFactor Source # 
Instance details

Defined in Vulkan.Core10.Enums.BlendFactor

Show BlendFactor Source # 
Instance details

Defined in Vulkan.Core10.Enums.BlendFactor

Eq BlendFactor Source # 
Instance details

Defined in Vulkan.Core10.Enums.BlendFactor

Ord BlendFactor Source # 
Instance details

Defined in Vulkan.Core10.Enums.BlendFactor

Zero BlendFactor Source # 
Instance details

Defined in Vulkan.Core10.Enums.BlendFactor