Package org.lwjgl.vulkan
Class VkPipelineColorBlendAttachmentState
java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<VkPipelineColorBlendAttachmentState>
org.lwjgl.vulkan.VkPipelineColorBlendAttachmentState
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
public class VkPipelineColorBlendAttachmentState
extends Struct<VkPipelineColorBlendAttachmentState>
implements NativeResource
Structure specifying a pipeline color blend attachment state.
Valid Usage
- If the
dualSrcBlend
feature is not enabled,srcColorBlendFactor
must not beBLEND_FACTOR_SRC1_COLOR
,BLEND_FACTOR_ONE_MINUS_SRC1_COLOR
,BLEND_FACTOR_SRC1_ALPHA
, orBLEND_FACTOR_ONE_MINUS_SRC1_ALPHA
- If the
dualSrcBlend
feature is not enabled,dstColorBlendFactor
must not beBLEND_FACTOR_SRC1_COLOR
,BLEND_FACTOR_ONE_MINUS_SRC1_COLOR
,BLEND_FACTOR_SRC1_ALPHA
, orBLEND_FACTOR_ONE_MINUS_SRC1_ALPHA
- If the
dualSrcBlend
feature is not enabled,srcAlphaBlendFactor
must not beBLEND_FACTOR_SRC1_COLOR
,BLEND_FACTOR_ONE_MINUS_SRC1_COLOR
,BLEND_FACTOR_SRC1_ALPHA
, orBLEND_FACTOR_ONE_MINUS_SRC1_ALPHA
- If the
dualSrcBlend
feature is not enabled,dstAlphaBlendFactor
must not beBLEND_FACTOR_SRC1_COLOR
,BLEND_FACTOR_ONE_MINUS_SRC1_COLOR
,BLEND_FACTOR_SRC1_ALPHA
, orBLEND_FACTOR_ONE_MINUS_SRC1_ALPHA
- If either of
colorBlendOp
oralphaBlendOp
is an advanced blend operation, thencolorBlendOp
must equalalphaBlendOp
- If
VkPhysicalDeviceBlendOperationAdvancedPropertiesEXT
::advancedBlendIndependentBlend
isFALSE
andcolorBlendOp
is an advanced blend operation, thencolorBlendOp
must be the same for all attachments - If
VkPhysicalDeviceBlendOperationAdvancedPropertiesEXT
::advancedBlendIndependentBlend
isFALSE
andalphaBlendOp
is an advanced blend operation, thenalphaBlendOp
must be the same for all attachments - If
VkPhysicalDeviceBlendOperationAdvancedPropertiesEXT
::advancedBlendAllOperations
isFALSE
, thencolorBlendOp
must not beBLEND_OP_ZERO_EXT
,BLEND_OP_SRC_EXT
,BLEND_OP_DST_EXT
,BLEND_OP_SRC_OVER_EXT
,BLEND_OP_DST_OVER_EXT
,BLEND_OP_SRC_IN_EXT
,BLEND_OP_DST_IN_EXT
,BLEND_OP_SRC_OUT_EXT
,BLEND_OP_DST_OUT_EXT
,BLEND_OP_SRC_ATOP_EXT
,BLEND_OP_DST_ATOP_EXT
,BLEND_OP_XOR_EXT
,BLEND_OP_INVERT_EXT
,BLEND_OP_INVERT_RGB_EXT
,BLEND_OP_LINEARDODGE_EXT
,BLEND_OP_LINEARBURN_EXT
,BLEND_OP_VIVIDLIGHT_EXT
,BLEND_OP_LINEARLIGHT_EXT
,BLEND_OP_PINLIGHT_EXT
,BLEND_OP_HARDMIX_EXT
,BLEND_OP_PLUS_EXT
,BLEND_OP_PLUS_CLAMPED_EXT
,BLEND_OP_PLUS_CLAMPED_ALPHA_EXT
,BLEND_OP_PLUS_DARKER_EXT
,BLEND_OP_MINUS_EXT
,BLEND_OP_MINUS_CLAMPED_EXT
,BLEND_OP_CONTRAST_EXT
,BLEND_OP_INVERT_OVG_EXT
,BLEND_OP_RED_EXT
,BLEND_OP_GREEN_EXT
, orBLEND_OP_BLUE_EXT
- If
colorBlendOp
oralphaBlendOp
is an advanced blend operation, thencolorAttachmentCount
of the subpass this pipeline is compiled against must be less than or equal toVkPhysicalDeviceBlendOperationAdvancedPropertiesEXT
::advancedBlendMaxColorAttachments
- If the
VK_KHR_portability_subset
extension is enabled, andVkPhysicalDevicePortabilitySubsetFeaturesKHR
::constantAlphaColorBlendFactors
isFALSE
,srcColorBlendFactor
must not beBLEND_FACTOR_CONSTANT_ALPHA
orBLEND_FACTOR_ONE_MINUS_CONSTANT_ALPHA
- If the
VK_KHR_portability_subset
extension is enabled, andVkPhysicalDevicePortabilitySubsetFeaturesKHR
::constantAlphaColorBlendFactors
isFALSE
,dstColorBlendFactor
must not beBLEND_FACTOR_CONSTANT_ALPHA
orBLEND_FACTOR_ONE_MINUS_CONSTANT_ALPHA
Valid Usage (Implicit)
srcColorBlendFactor
must be a validVkBlendFactor
valuedstColorBlendFactor
must be a validVkBlendFactor
valuecolorBlendOp
must be a validVkBlendOp
valuesrcAlphaBlendFactor
must be a validVkBlendFactor
valuedstAlphaBlendFactor
must be a validVkBlendFactor
valuealphaBlendOp
must be a validVkBlendOp
valuecolorWriteMask
must be a valid combination ofVkColorComponentFlagBits
values
See Also
VkPipelineColorBlendStateCreateInfo
Layout
struct VkPipelineColorBlendAttachmentState {
VkBool32 blendEnable()
;
VkBlendFactor srcColorBlendFactor()
;
VkBlendFactor dstColorBlendFactor()
;
VkBlendOp colorBlendOp()
;
VkBlendFactor srcAlphaBlendFactor()
;
VkBlendFactor dstAlphaBlendFactor()
;
VkBlendOp alphaBlendOp()
;
VkColorComponentFlags colorWriteMask()
;
}
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
An array ofVkPipelineColorBlendAttachmentState
structs.Nested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
The struct alignment in bytes.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct size in bytes.static final int
The struct member offsets.static final int
The struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionVkPipelineColorBlendAttachmentState
(ByteBuffer container) Creates aVkPipelineColorBlendAttachmentState
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionint
selects which blend operation is used to calculate the alpha values to write to the color attachment.alphaBlendOp
(int value) Sets the specified value to thealphaBlendOp()
field.boolean
controls whether blending is enabled for the corresponding color attachment.blendEnable
(boolean value) Sets the specified value to theblendEnable()
field.calloc()
Returns a newVkPipelineColorBlendAttachmentState
instance allocated withmemCalloc
.calloc
(int capacity) Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated withmemCalloc
.calloc
(int capacity, MemoryStack stack) Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.calloc
(MemoryStack stack) Returns a newVkPipelineColorBlendAttachmentState
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.Deprecated.callocStack
(int capacity) Deprecated.callocStack
(int capacity, MemoryStack stack) Deprecated.callocStack
(MemoryStack stack) Deprecated.int
selects which blend operation is used to calculate the RGB values to write to the color attachment.colorBlendOp
(int value) Sets the specified value to thecolorBlendOp()
field.int
a bitmask ofVkColorComponentFlagBits
specifying which of the R, G, B, and/or A components are enabled for writing, as described for the Color Write Mask.colorWriteMask
(int value) Sets the specified value to thecolorWriteMask()
field.create()
Returns a newVkPipelineColorBlendAttachmentState
instance allocated withBufferUtils
.create
(int capacity) Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated withBufferUtils
.create
(long address) Returns a newVkPipelineColorBlendAttachmentState
instance for the specified memory address.create
(long address, int capacity) Create aVkPipelineColorBlendAttachmentState.Buffer
instance at the specified memory.createSafe
(long address) createSafe
(long address, int capacity) int
selects which blend factor is used to determine the destination factorDa
.dstAlphaBlendFactor
(int value) Sets the specified value to thedstAlphaBlendFactor()
field.int
selects which blend factor is used to determine the destination factors(Dr,Dg,Db)
.dstColorBlendFactor
(int value) Sets the specified value to thedstColorBlendFactor()
field.malloc()
Returns a newVkPipelineColorBlendAttachmentState
instance allocated withmemAlloc
.malloc
(int capacity) Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated withmemAlloc
.malloc
(int capacity, MemoryStack stack) Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated on the specifiedMemoryStack
.malloc
(MemoryStack stack) Returns a newVkPipelineColorBlendAttachmentState
instance allocated on the specifiedMemoryStack
.Deprecated.mallocStack
(int capacity) Deprecated.mallocStack
(int capacity, MemoryStack stack) Deprecated.mallocStack
(MemoryStack stack) Deprecated.static int
nalphaBlendOp
(long struct) Unsafe version ofalphaBlendOp()
.static void
nalphaBlendOp
(long struct, int value) Unsafe version ofalphaBlendOp
.static int
nblendEnable
(long struct) Unsafe version ofblendEnable()
.static void
nblendEnable
(long struct, int value) Unsafe version ofblendEnable
.static int
ncolorBlendOp
(long struct) Unsafe version ofcolorBlendOp()
.static void
ncolorBlendOp
(long struct, int value) Unsafe version ofcolorBlendOp
.static int
ncolorWriteMask
(long struct) Unsafe version ofcolorWriteMask()
.static void
ncolorWriteMask
(long struct, int value) Unsafe version ofcolorWriteMask
.static int
ndstAlphaBlendFactor
(long struct) Unsafe version ofdstAlphaBlendFactor()
.static void
ndstAlphaBlendFactor
(long struct, int value) Unsafe version ofdstAlphaBlendFactor
.static int
ndstColorBlendFactor
(long struct) Unsafe version ofdstColorBlendFactor()
.static void
ndstColorBlendFactor
(long struct, int value) Unsafe version ofdstColorBlendFactor
.static int
nsrcAlphaBlendFactor
(long struct) Unsafe version ofsrcAlphaBlendFactor()
.static void
nsrcAlphaBlendFactor
(long struct, int value) Unsafe version ofsrcAlphaBlendFactor
.static int
nsrcColorBlendFactor
(long struct) Unsafe version ofsrcColorBlendFactor()
.static void
nsrcColorBlendFactor
(long struct, int value) Unsafe version ofsrcColorBlendFactor
.set
(boolean blendEnable, int srcColorBlendFactor, int dstColorBlendFactor, int colorBlendOp, int srcAlphaBlendFactor, int dstAlphaBlendFactor, int alphaBlendOp, int colorWriteMask) Initializes this struct with the specified values.Copies the specified struct data to this struct.int
sizeof()
Returnssizeof(struct)
.int
selects which blend factor is used to determine the source factorSa
.srcAlphaBlendFactor
(int value) Sets the specified value to thesrcAlphaBlendFactor()
field.int
selects which blend factor is used to determine the source factors(Sr,Sg,Sb)
.srcColorBlendFactor
(int value) Sets the specified value to thesrcColorBlendFactor()
field.Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
BLENDENABLE
public static final int BLENDENABLEThe struct member offsets. -
SRCCOLORBLENDFACTOR
public static final int SRCCOLORBLENDFACTORThe struct member offsets. -
DSTCOLORBLENDFACTOR
public static final int DSTCOLORBLENDFACTORThe struct member offsets. -
COLORBLENDOP
public static final int COLORBLENDOPThe struct member offsets. -
SRCALPHABLENDFACTOR
public static final int SRCALPHABLENDFACTORThe struct member offsets. -
DSTALPHABLENDFACTOR
public static final int DSTALPHABLENDFACTORThe struct member offsets. -
ALPHABLENDOP
public static final int ALPHABLENDOPThe struct member offsets. -
COLORWRITEMASK
public static final int COLORWRITEMASKThe struct member offsets.
-
-
Constructor Details
-
VkPipelineColorBlendAttachmentState
Creates aVkPipelineColorBlendAttachmentState
instance at the current position of the specifiedByteBuffer
container. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Details
-
sizeof
public int sizeof()Description copied from class:Struct
Returnssizeof(struct)
.- Specified by:
sizeof
in classStruct<VkPipelineColorBlendAttachmentState>
-
blendEnable
public boolean blendEnable()controls whether blending is enabled for the corresponding color attachment. If blending is not enabled, the source fragment’s color for that attachment is passed through unmodified. -
srcColorBlendFactor
public int srcColorBlendFactor()selects which blend factor is used to determine the source factors(Sr,Sg,Sb)
. -
dstColorBlendFactor
public int dstColorBlendFactor()selects which blend factor is used to determine the destination factors(Dr,Dg,Db)
. -
colorBlendOp
public int colorBlendOp()selects which blend operation is used to calculate the RGB values to write to the color attachment. -
srcAlphaBlendFactor
public int srcAlphaBlendFactor()selects which blend factor is used to determine the source factorSa
. -
dstAlphaBlendFactor
public int dstAlphaBlendFactor()selects which blend factor is used to determine the destination factorDa
. -
alphaBlendOp
public int alphaBlendOp()selects which blend operation is used to calculate the alpha values to write to the color attachment. -
colorWriteMask
public int colorWriteMask()a bitmask ofVkColorComponentFlagBits
specifying which of the R, G, B, and/or A components are enabled for writing, as described for the Color Write Mask. -
blendEnable
Sets the specified value to theblendEnable()
field. -
srcColorBlendFactor
Sets the specified value to thesrcColorBlendFactor()
field. -
dstColorBlendFactor
Sets the specified value to thedstColorBlendFactor()
field. -
colorBlendOp
Sets the specified value to thecolorBlendOp()
field. -
srcAlphaBlendFactor
Sets the specified value to thesrcAlphaBlendFactor()
field. -
dstAlphaBlendFactor
Sets the specified value to thedstAlphaBlendFactor()
field. -
alphaBlendOp
Sets the specified value to thealphaBlendOp()
field. -
colorWriteMask
Sets the specified value to thecolorWriteMask()
field. -
set
public VkPipelineColorBlendAttachmentState set(boolean blendEnable, int srcColorBlendFactor, int dstColorBlendFactor, int colorBlendOp, int srcAlphaBlendFactor, int dstAlphaBlendFactor, int alphaBlendOp, int colorWriteMask) Initializes this struct with the specified values. -
set
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
Returns a newVkPipelineColorBlendAttachmentState
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newVkPipelineColorBlendAttachmentState
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newVkPipelineColorBlendAttachmentState
instance allocated withBufferUtils
. -
create
Returns a newVkPipelineColorBlendAttachmentState
instance for the specified memory address. -
createSafe
-
malloc
Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aVkPipelineColorBlendAttachmentState.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static VkPipelineColorBlendAttachmentState.Buffer createSafe(long address, int capacity) -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
mallocStack
@Deprecated public static VkPipelineColorBlendAttachmentState.Buffer mallocStack(int capacity, MemoryStack stack) Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
@Deprecated public static VkPipelineColorBlendAttachmentState.Buffer callocStack(int capacity, MemoryStack stack) Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
malloc
Returns a newVkPipelineColorBlendAttachmentState
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newVkPipelineColorBlendAttachmentState
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newVkPipelineColorBlendAttachmentState.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
nblendEnable
public static int nblendEnable(long struct) Unsafe version ofblendEnable()
. -
nsrcColorBlendFactor
public static int nsrcColorBlendFactor(long struct) Unsafe version ofsrcColorBlendFactor()
. -
ndstColorBlendFactor
public static int ndstColorBlendFactor(long struct) Unsafe version ofdstColorBlendFactor()
. -
ncolorBlendOp
public static int ncolorBlendOp(long struct) Unsafe version ofcolorBlendOp()
. -
nsrcAlphaBlendFactor
public static int nsrcAlphaBlendFactor(long struct) Unsafe version ofsrcAlphaBlendFactor()
. -
ndstAlphaBlendFactor
public static int ndstAlphaBlendFactor(long struct) Unsafe version ofdstAlphaBlendFactor()
. -
nalphaBlendOp
public static int nalphaBlendOp(long struct) Unsafe version ofalphaBlendOp()
. -
ncolorWriteMask
public static int ncolorWriteMask(long struct) Unsafe version ofcolorWriteMask()
. -
nblendEnable
public static void nblendEnable(long struct, int value) Unsafe version ofblendEnable
. -
nsrcColorBlendFactor
public static void nsrcColorBlendFactor(long struct, int value) Unsafe version ofsrcColorBlendFactor
. -
ndstColorBlendFactor
public static void ndstColorBlendFactor(long struct, int value) Unsafe version ofdstColorBlendFactor
. -
ncolorBlendOp
public static void ncolorBlendOp(long struct, int value) Unsafe version ofcolorBlendOp
. -
nsrcAlphaBlendFactor
public static void nsrcAlphaBlendFactor(long struct, int value) Unsafe version ofsrcAlphaBlendFactor
. -
ndstAlphaBlendFactor
public static void ndstAlphaBlendFactor(long struct, int value) Unsafe version ofdstAlphaBlendFactor
. -
nalphaBlendOp
public static void nalphaBlendOp(long struct, int value) Unsafe version ofalphaBlendOp
. -
ncolorWriteMask
public static void ncolorWriteMask(long struct, int value) Unsafe version ofcolorWriteMask
.
-