Class VkSubpassDescription2
- All Implemented Interfaces:
AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
- Direct Known Subclasses:
VkSubpassDescription2KHR
Description
Parameters defined by this structure with the same name as those in VkSubpassDescription have the identical effect to those parameters.
viewMask has the same effect for the described subpass as VkRenderPassMultiviewCreateInfo::pViewMasks has on each corresponding subpass.
If a VkFragmentShadingRateAttachmentInfoKHR structure is included in the pNext chain, pFragmentShadingRateAttachment is not NULL, and its attachment member is not ATTACHMENT_UNUSED, the identified attachment defines a fragment shading rate attachment for that subpass.
If any element of pResolveAttachments is an image specified with an VkExternalFormatANDROID, values in the corresponding color attachment will be resolved to the resolve attachment in the same manner as specified for RESOLVE_MODE_EXTERNAL_FORMAT_DOWNSAMPLE_ANDROID (VkResolveModeFlagBits).
If the nullColorAttachmentWithExternalFormatResolve limit is TRUE, values in the color attachment will be loaded from the resolve attachment at the start of rendering, and may also be reloaded any time after a resolve occurs or the resolve attachment is written to; if this occurs it must happen-before any writes to the color attachment are performed which happen-after the resolve that triggers this. If any color component in the external format is subsampled, values will be read from the nearest sample in the image when they are loaded. If the color attachment is also used as an input attachment, the same behavior applies.
Setting the color attachment to ATTACHMENT_UNUSED when an external resolve attachment is used and the nullColorAttachmentWithExternalFormatResolve limit is TRUE will not result in color attachment writes to be discarded for that attachment.
When nullColorAttachmentWithExternalFormatResolve is TRUE, the color output from the subpass can still be read via an input attachment; but the application cannot bind an image view for the color attachment as there is no such image view bound. Instead to access the data as an input attachment applications can use the resolve attachment in its place - using the resolve attachment image for the descriptor, and setting the corresponding element of pInputAttachments to the index of the resolve attachment.
Loads or input attachment reads from the resolve attachment are performed as if using a VkSamplerYcbcrConversionCreateInfo with the following parameters:
VkSamplerYcbcrConversionCreateInfo createInfo = {
.sType = VK_STRUCTURE_TYPE_SAMPLER_YCBCR_CONVERSION_CREATE_INFO,
.pNext = NULL,
.format = VK_FORMAT_UNDEFINED,
.ycbcrModel = VK_SAMPLER_YCBCR_MODEL_CONVERSION_RGB_IDENTITY,
.ycbcrRange = VK_SAMPLER_YCBCR_RANGE_ITU_FULL,
.components = {
.r = VK_COMPONENT_SWIZZLE_B
.g = VK_COMPONENT_SWIZZLE_R
.b = VK_COMPONENT_SWIZZLE_G
.a = VK_COMPONENT_SWIZZLE_IDENTITY},
.xChromaOffset = properties.chromaOffsetX,
.yChromaOffset = properties.chromaOffsetY,
.chromaFilter = VK_FILTER_NEAREST,
.forceExplicitReconstruction = ... };
where properties is equal to VkPhysicalDeviceExternalFormatResolvePropertiesANDROID returned by the device and forceExplicitReconstruction is effectively ignored as the SAMPLER_YCBCR_MODEL_CONVERSION_RGB_IDENTITY model is used. The applied swizzle is the same effective swizzle that would be applied by the SAMPLER_YCBCR_MODEL_CONVERSION_YCBCR_IDENTITY model, but no range expansion is applied.
Valid Usage
- If the
attachmentmember of an element ofpInputAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMALorIMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL - If the
attachmentmember of an element ofpColorAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMALorIMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL - If the
attachmentmember of an element ofpResolveAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMALorIMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL - If the
attachmentmember ofpDepthStencilAttachmentis notATTACHMENT_UNUSED, tslayoutmember must not beIMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMALorIMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL - If the
attachmentmember of an element ofpColorAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_OPTIMALorIMAGE_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_OPTIMAL - If the
attachmentmember of an element ofpResolveAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_OPTIMALorIMAGE_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_OPTIMAL - If the
attachmentmember of an element ofpInputAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_ATTACHMENT_OPTIMALorIMAGE_LAYOUT_STENCIL_ATTACHMENT_OPTIMAL - If the
attachmentmember of an element ofpColorAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_ATTACHMENT_OPTIMAL,IMAGE_LAYOUT_DEPTH_READ_ONLY_OPTIMAL,IMAGE_LAYOUT_STENCIL_ATTACHMENT_OPTIMAL, orIMAGE_LAYOUT_STENCIL_READ_ONLY_OPTIMAL - If the
attachmentmember of an element ofpResolveAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_DEPTH_ATTACHMENT_OPTIMAL,IMAGE_LAYOUT_DEPTH_READ_ONLY_OPTIMAL,IMAGE_LAYOUT_STENCIL_ATTACHMENT_OPTIMAL, orIMAGE_LAYOUT_STENCIL_READ_ONLY_OPTIMAL - If the
attachmentmember of an element ofpInputAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_ATTACHMENT_OPTIMAL_KHR - If the
attachmentmember of an element ofpColorAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_READ_ONLY_OPTIMAL_KHR - If the
attachmentmember of an element ofpResolveAttachmentsis notATTACHMENT_UNUSED, itslayoutmember must not beIMAGE_LAYOUT_READ_ONLY_OPTIMAL_KHR - If the
attachmentmember ofpDepthStencilAttachmentis notATTACHMENT_UNUSEDand itspNextchain includes aVkAttachmentReferenceStencilLayoutstructure, thelayoutmember ofpDepthStencilAttachmentmust not beIMAGE_LAYOUT_STENCIL_ATTACHMENT_OPTIMALorIMAGE_LAYOUT_STENCIL_READ_ONLY_OPTIMAL pipelineBindPointmust bePIPELINE_BIND_POINT_GRAPHICSorPIPELINE_BIND_POINT_SUBPASS_SHADING_HUAWEIcolorAttachmentCountmust be less than or equal toVkPhysicalDeviceLimits::maxColorAttachments- If the first use of an attachment in this render pass is as an input attachment, and the attachment is not also used as a color or depth/stencil attachment in the same subpass, then
loadOpmust not beATTACHMENT_LOAD_OP_CLEAR - If
pResolveAttachmentsis notNULL, each resolve attachment that is notATTACHMENT_UNUSEDmust have a sample count ofSAMPLE_COUNT_1_BIT - If the
externalFormatResolvefeature is not enabled andpResolveAttachmentsis notNULL, for each resolve attachment that does not have the valueATTACHMENT_UNUSED, the corresponding color attachment must not have the valueATTACHMENT_UNUSED - If the
nullColorAttachmentWithExternalFormatResolveproperty isFALSEandpResolveAttachmentsis notNULL, for each resolve attachment that has a format ofFORMAT_UNDEFINED, the corresponding color attachment must not have the valueATTACHMENT_UNUSED - If the
nullColorAttachmentWithExternalFormatResolveproperty isTRUEandpResolveAttachmentsis notNULL, for each resolve attachment that has a format ofFORMAT_UNDEFINED, the corresponding color attachment must have the valueATTACHMENT_UNUSED - If the
externalFormatResolvefeature is not enabled andpResolveAttachmentsis notNULL, for each resolve attachment that is notATTACHMENT_UNUSED, the corresponding color attachment must not have a sample count ofSAMPLE_COUNT_1_BIT - If the
externalFormatResolvefeature is not enabled, each element ofpResolveAttachmentsmust have the sameVkFormatas its corresponding color attachment - If the
multisampledRenderToSingleSampledfeature is not enabled, all attachments inpColorAttachmentsthat are notATTACHMENT_UNUSEDmust have the same sample count - All attachments in
pInputAttachmentsthat are notATTACHMENT_UNUSEDand any of the following is true:- the
externalFormatResolvefeature is not enabled - the
nullColorAttachmentWithExternalFormatResolveproperty isFALSE - does not have a non-zero value of
VkExternalFormatANDROID::externalFormat
must have image formats whose potential format features contain at least
FORMAT_FEATURE_COLOR_ATTACHMENT_BITorFORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT - the
- All attachments in
pColorAttachmentsthat are notATTACHMENT_UNUSEDmust have image formats whose potential format features containFORMAT_FEATURE_COLOR_ATTACHMENT_BIT - All attachments in
pResolveAttachmentsthat are notATTACHMENT_UNUSEDand do not have an image format ofFORMAT_UNDEFINEDmust have image formats whose potential format features containFORMAT_FEATURE_COLOR_ATTACHMENT_BIT - If
pDepthStencilAttachmentis notNULLand the attachment is notATTACHMENT_UNUSEDthen it must have an image format whose potential format features containFORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT - If the
linearColorAttachmentfeature is enabled and the image is created withIMAGE_TILING_LINEAR, all attachments inpInputAttachmentsthat are notATTACHMENT_UNUSEDmust have image formats whose potential format features must containFORMAT_FEATURE_2_LINEAR_COLOR_ATTACHMENT_BIT_NV - If the
linearColorAttachmentfeature is enabled and the image is created withIMAGE_TILING_LINEAR, all attachments inpColorAttachmentsthat are notATTACHMENT_UNUSEDmust have image formats whose potential format features must containFORMAT_FEATURE_2_LINEAR_COLOR_ATTACHMENT_BIT_NV - If the
linearColorAttachmentfeature is enabled and the image is created withIMAGE_TILING_LINEAR, all attachments inpResolveAttachmentsthat are notATTACHMENT_UNUSEDmust have image formats whose potential format features must containFORMAT_FEATURE_2_LINEAR_COLOR_ATTACHMENT_BIT_NV - If either of the following is enabled:
- The
VK_AMD_mixed_attachment_samplesextension - The
VK_NV_framebuffer_mixed_samplesextension
all attachments in
pColorAttachmentsthat are notATTACHMENT_UNUSEDmust have a sample count that is smaller than or equal to the sample count ofpDepthStencilAttachmentif it is notATTACHMENT_UNUSED - The
- If the
pNextchain includes aVkMultisampledRenderToSingleSampledInfoEXTstructure withmultisampledRenderToSingleSampledEnableequal toTRUE, then all attachments inpColorAttachmentsandpDepthStencilAttachmentthat are notATTACHMENT_UNUSEDmust have a sample count that is eitherSAMPLE_COUNT_1_BITor equal toVkMultisampledRenderToSingleSampledInfoEXT::rasterizationSamples - If the
pNextchain includes aVkMultisampledRenderToSingleSampledInfoEXTstructure withmultisampledRenderToSingleSampledEnableequal toTRUE, andpDepthStencilAttachmentis notNULL, does not have the valueATTACHMENT_UNUSED, and has a sample count ofSAMPLE_COUNT_1_BIT, thepNextchain must also include aVkSubpassDescriptionDepthStencilResolvestructure withpDepthStencilResolveAttachmentthat is eitherNULLor has the valueATTACHMENT_UNUSED - All attachments in
pDepthStencilAttachmentorpColorAttachmentsthat are notATTACHMENT_UNUSEDmust have the same sample count , if none of the following are enabled:- The
VK_AMD_mixed_attachment_samplesextension - The
VK_NV_framebuffer_mixed_samplesextension - The
multisampledRenderToSingleSampledfeature,
- The
- Each element of
pPreserveAttachmentsmust not beATTACHMENT_UNUSED - Each element of
pPreserveAttachmentsmust not also be an element of any other member of the subpass description - If any attachment is used by more than one
VkAttachmentReference2member, then each use must use the samelayout - If
flagsincludesSUBPASS_DESCRIPTION_PER_VIEW_POSITION_X_ONLY_BIT_NVX, it must also includeSUBPASS_DESCRIPTION_PER_VIEW_ATTRIBUTES_BIT_NVX - If the
attachmentmember of any element ofpInputAttachmentsis notATTACHMENT_UNUSED, then theaspectMaskmember must be a valid combination ofVkImageAspectFlagBits - If the
attachmentmember of any element ofpInputAttachmentsis notATTACHMENT_UNUSED, then theaspectMaskmember must not be 0 - If the
attachmentmember of any element ofpInputAttachmentsis notATTACHMENT_UNUSED, then theaspectMaskmember must not includeIMAGE_ASPECT_METADATA_BIT - If the
attachmentmember of any element ofpInputAttachmentsis notATTACHMENT_UNUSED, then theaspectMaskmember must not includeVK_IMAGE_ASPECT_MEMORY_PLANE_i_BIT_EXTfor any index i - An attachment must not be used in both
pDepthStencilAttachmentandpColorAttachments - If the
multiviewfeature is not enabled,viewMaskmust be 0 - The index of the most significant bit in
viewMaskmust be less thanmaxMultiviewViewCount - If the
externalFormatResolvefeature is enabled,pResolveAttachmentsis notNULL, andcolorAttachmentCountis not 1, any element ofpResolveAttachmentsthat is notVK_ATTACHMENT_UNUSED, must not have a format ofFORMAT_UNDEFINED - If the
externalFormatResolvefeature is enabled,pResolveAttachmentsis notNULL, any element ofpResolveAttachmentsis notATTACHMENT_UNUSEDand has a format ofFORMAT_UNDEFINED, and the corresponding element ofpColorAttachmentsis notATTACHMENT_UNUSED, the color attachment must have asamplesvalue of 1 - If the
externalFormatResolvefeature is enabled,pResolveAttachmentsis notNULL, and any element ofpResolveAttachmentsis notATTACHMENT_UNUSEDand has a format ofFORMAT_UNDEFINED,viewMaskmust be 0 - If the
externalFormatResolvefeature is enabled,pResolveAttachmentsis notNULL, and any element ofpResolveAttachmentsis notATTACHMENT_UNUSEDand has a format ofFORMAT_UNDEFINED,VkFragmentShadingRateAttachmentInfoKHR::pFragmentShadingRateAttachmentmust either beNULLor aVkAttachmentReference2structure with anattachmentvalue ofATTACHMENT_UNUSED - If the
externalFormatResolvefeature is enabled,pResolveAttachmentsis notNULL, and any element ofpResolveAttachmentsis notATTACHMENT_UNUSEDand has a format ofFORMAT_UNDEFINED, elements ofpInputAttachmentsreferencing either a color attachment or resolve attachment used in this subpass must not includeVK_IMAGE_ASPECT_PLANE_i_BITfor any index i in itsaspectMask
Valid Usage (Implicit)
sTypemust beSTRUCTURE_TYPE_SUBPASS_DESCRIPTION_2- Each
pNextmember of any structure (including this one) in thepNextchain must be eitherNULLor a pointer to a valid instance ofVkFragmentShadingRateAttachmentInfoKHR,VkMultisampledRenderToSingleSampledInfoEXT,VkRenderPassCreationControlEXT,VkRenderPassSubpassFeedbackCreateInfoEXT, orVkSubpassDescriptionDepthStencilResolve - The
sTypevalue of each struct in thepNextchain must be unique flagsmust be a valid combination ofVkSubpassDescriptionFlagBitsvaluespipelineBindPointmust be a validVkPipelineBindPointvalue- If
inputAttachmentCountis not 0,pInputAttachmentsmust be a valid pointer to an array ofinputAttachmentCountvalidVkAttachmentReference2structures - If
colorAttachmentCountis not 0,pColorAttachmentsmust be a valid pointer to an array ofcolorAttachmentCountvalidVkAttachmentReference2structures - If
colorAttachmentCountis not 0, andpResolveAttachmentsis notNULL,pResolveAttachmentsmust be a valid pointer to an array ofcolorAttachmentCountvalidVkAttachmentReference2structures - If
pDepthStencilAttachmentis notNULL,pDepthStencilAttachmentmust be a valid pointer to a validVkAttachmentReference2structure - If
preserveAttachmentCountis not 0,pPreserveAttachmentsmust be a valid pointer to an array ofpreserveAttachmentCountuint32_tvalues
See Also
VkAttachmentReference2, VkRenderPassCreateInfo2
Layout
struct VkSubpassDescription2 {
VkStructureType sType();
void const * pNext();
VkSubpassDescriptionFlags flags();
VkPipelineBindPoint pipelineBindPoint();
uint32_t viewMask();
uint32_t inputAttachmentCount();
VkAttachmentReference2 const * pInputAttachments();
uint32_t colorAttachmentCount();
VkAttachmentReference2 const * pColorAttachments();
VkAttachmentReference2 const * pResolveAttachments();
VkAttachmentReference2 const * pDepthStencilAttachment();
uint32_t preserveAttachmentCount();
uint32_t const * pPreserveAttachments();
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
org.lwjgl.system.Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
org.lwjgl.system.Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.static final intThe struct member offsets.static final intThe struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionVkSubpassDescription2(ByteBuffer container) Creates aVkSubpassDescription2instance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionstatic VkSubpassDescription2calloc()Returns a newVkSubpassDescription2instance allocated withmemCalloc.static VkSubpassDescription2.Buffercalloc(int capacity) Returns a newVkSubpassDescription2.Bufferinstance allocated withmemCalloc.static VkSubpassDescription2.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newVkSubpassDescription2.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkSubpassDescription2calloc(org.lwjgl.system.MemoryStack stack) Returns a newVkSubpassDescription2instance allocated on the specifiedMemoryStackand initializes all its bits to zero.intthe number of color attachments.colorAttachmentCount(int value) Sets the specified value to thecolorAttachmentCount()field.static VkSubpassDescription2create()Returns a newVkSubpassDescription2instance allocated withBufferUtils.static VkSubpassDescription2.Buffercreate(int capacity) Returns a newVkSubpassDescription2.Bufferinstance allocated withBufferUtils.static VkSubpassDescription2create(long address) Returns a newVkSubpassDescription2instance for the specified memory address.static VkSubpassDescription2.Buffercreate(long address, int capacity) Create aVkSubpassDescription2.Bufferinstance at the specified memory.static @Nullable VkSubpassDescription2createSafe(long address) static @Nullable VkSubpassDescription2.BuffercreateSafe(long address, int capacity) intflags()a bitmask ofVkSubpassDescriptionFlagBitsspecifying usage of the subpass.flags(int value) Sets the specified value to theflags()field.intthe number of input attachments.static VkSubpassDescription2malloc()Returns a newVkSubpassDescription2instance allocated withmemAlloc.static VkSubpassDescription2.Buffermalloc(int capacity) Returns a newVkSubpassDescription2.Bufferinstance allocated withmemAlloc.static VkSubpassDescription2.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newVkSubpassDescription2.Bufferinstance allocated on the specifiedMemoryStack.static VkSubpassDescription2malloc(org.lwjgl.system.MemoryStack stack) Returns a newVkSubpassDescription2instance allocated on the specifiedMemoryStack.static intncolorAttachmentCount(long struct) Unsafe version ofcolorAttachmentCount().static voidncolorAttachmentCount(long struct, int value) Sets the specified value to thecolorAttachmentCountfield of the specifiedstruct.static intnflags(long struct) Unsafe version offlags().static voidnflags(long struct, int value) Unsafe version offlags.static intninputAttachmentCount(long struct) Unsafe version ofinputAttachmentCount().static voidninputAttachmentCount(long struct, int value) Sets the specified value to theinputAttachmentCountfield of the specifiedstruct.static @Nullable VkAttachmentReference2.BuffernpColorAttachments(long struct) Unsafe version ofpColorAttachments().static voidnpColorAttachments(long struct, @Nullable VkAttachmentReference2.Buffer value) Unsafe version ofpColorAttachments.static @Nullable VkAttachmentReference2npDepthStencilAttachment(long struct) Unsafe version ofpDepthStencilAttachment().static voidnpDepthStencilAttachment(long struct, @Nullable VkAttachmentReference2 value) Unsafe version ofpDepthStencilAttachment.static @Nullable VkAttachmentReference2.BuffernpInputAttachments(long struct) Unsafe version ofpInputAttachments().static voidnpInputAttachments(long struct, @Nullable VkAttachmentReference2.Buffer value) Unsafe version ofpInputAttachments.static intnpipelineBindPoint(long struct) Unsafe version ofpipelineBindPoint().static voidnpipelineBindPoint(long struct, int value) Unsafe version ofpipelineBindPoint.static longnpNext(long struct) Unsafe version ofpNext().static voidnpNext(long struct, long value) Unsafe version ofpNext.static @Nullable IntBuffernpPreserveAttachments(long struct) Unsafe version ofpPreserveAttachments.static voidnpPreserveAttachments(long struct, @Nullable IntBuffer value) Unsafe version ofpPreserveAttachments.static intnpreserveAttachmentCount(long struct) Unsafe version ofpreserveAttachmentCount().static voidnpreserveAttachmentCount(long struct, int value) Sets the specified value to thepreserveAttachmentCountfield of the specifiedstruct.static @Nullable VkAttachmentReference2.BuffernpResolveAttachments(long struct) Unsafe version ofpResolveAttachments().static voidnpResolveAttachments(long struct, @Nullable VkAttachmentReference2.Buffer value) Unsafe version ofpResolveAttachments.static intnsType(long struct) Unsafe version ofsType().static voidnsType(long struct, int value) Unsafe version ofsType.static intnviewMask(long struct) Unsafe version ofviewMask().static voidnviewMask(long struct, int value) Unsafe version ofviewMask.@Nullable VkAttachmentReference2.Buffera pointer to an array ofcolorAttachmentCountVkAttachmentReference2structures defining the color attachments for this subpass and their layouts.pColorAttachments(@Nullable VkAttachmentReference2.Buffer value) Sets the address of the specifiedVkAttachmentReference2.Bufferto thepColorAttachments()field.@Nullable VkAttachmentReference2a pointer to aVkAttachmentReference2structure specifying the depth/stencil attachment for this subpass and its layout.pDepthStencilAttachment(@Nullable VkAttachmentReference2 value) Sets the address of the specifiedVkAttachmentReference2to thepDepthStencilAttachment()field.@Nullable VkAttachmentReference2.Buffera pointer to an array ofVkAttachmentReference2structures defining the input attachments for this subpass and their layouts.pInputAttachments(@Nullable VkAttachmentReference2.Buffer value) Sets the address of the specifiedVkAttachmentReference2.Bufferto thepInputAttachments()field.intaVkPipelineBindPointvalue specifying the pipeline type supported for this subpass.pipelineBindPoint(int value) Sets the specified value to thepipelineBindPoint()field.longpNext()NULLor a pointer to a structure extending this structure.pNext(long value) Sets the specified value to thepNext()field.Prepends the specifiedVkFragmentShadingRateAttachmentInfoKHRvalue to thepNextchain.Prepends the specifiedVkMultisampledRenderToSingleSampledInfoEXTvalue to thepNextchain.Prepends the specifiedVkRenderPassCreationControlEXTvalue to thepNextchain.Prepends the specifiedVkRenderPassSubpassFeedbackCreateInfoEXTvalue to thepNextchain.Prepends the specifiedVkSubpassDescriptionDepthStencilResolvevalue to thepNextchain.Prepends the specifiedVkSubpassDescriptionDepthStencilResolveKHRvalue to thepNextchain.@Nullable IntBuffera pointer to an array ofpreserveAttachmentCountrender pass attachment indices identifying attachments that are not used by this subpass, but whose contents must be preserved throughout the subpass.pPreserveAttachments(@Nullable IntBuffer value) Sets the address of the specifiedIntBufferto thepPreserveAttachments()field.intthe number of preserved attachments.@Nullable VkAttachmentReference2.BufferNULLor a pointer to an array ofcolorAttachmentCountVkAttachmentReference2structures defining the resolve attachments for this subpass and their layouts.pResolveAttachments(@Nullable VkAttachmentReference2.Buffer value) Sets the address of the specifiedVkAttachmentReference2.Bufferto thepResolveAttachments()field.set(int sType, long pNext, int flags, int pipelineBindPoint, int viewMask, @Nullable VkAttachmentReference2.Buffer pInputAttachments, int colorAttachmentCount, @Nullable VkAttachmentReference2.Buffer pColorAttachments, @Nullable VkAttachmentReference2.Buffer pResolveAttachments, @Nullable VkAttachmentReference2 pDepthStencilAttachment, @Nullable IntBuffer pPreserveAttachments) Initializes this struct with the specified values.set(VkSubpassDescription2 src) Copies the specified struct data to this struct.intsizeof()intsType()aVkStructureTypevalue identifying this structure.sType(int value) Sets the specified value to thesType()field.Sets theSTRUCTURE_TYPE_SUBPASS_DESCRIPTION_2value to thesType()field.static voidvalidate(long struct) Validates pointer members that should not beNULL.intviewMask()a bitfield of view indices describing which views rendering is broadcast to in this subpass, when multiview is enabled.viewMask(int value) Sets the specified value to theviewMask()field.Methods inherited from class org.lwjgl.system.Struct
clear, free, isNull, validate, validateMethods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods 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. -
STYPE
public static final int STYPEThe struct member offsets. -
PNEXT
public static final int PNEXTThe struct member offsets. -
FLAGS
public static final int FLAGSThe struct member offsets. -
PIPELINEBINDPOINT
public static final int PIPELINEBINDPOINTThe struct member offsets. -
VIEWMASK
public static final int VIEWMASKThe struct member offsets. -
INPUTATTACHMENTCOUNT
public static final int INPUTATTACHMENTCOUNTThe struct member offsets. -
PINPUTATTACHMENTS
public static final int PINPUTATTACHMENTSThe struct member offsets. -
COLORATTACHMENTCOUNT
public static final int COLORATTACHMENTCOUNTThe struct member offsets. -
PCOLORATTACHMENTS
public static final int PCOLORATTACHMENTSThe struct member offsets. -
PRESOLVEATTACHMENTS
public static final int PRESOLVEATTACHMENTSThe struct member offsets. -
PDEPTHSTENCILATTACHMENT
public static final int PDEPTHSTENCILATTACHMENTThe struct member offsets. -
PRESERVEATTACHMENTCOUNT
public static final int PRESERVEATTACHMENTCOUNTThe struct member offsets. -
PPRESERVEATTACHMENTS
public static final int PPRESERVEATTACHMENTSThe struct member offsets.
-
-
Constructor Details
-
VkSubpassDescription2
Creates aVkSubpassDescription2instance at the current position of the specifiedByteBuffercontainer. 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()- Specified by:
sizeofin classorg.lwjgl.system.Struct<VkSubpassDescription2>
-
sType
public int sType()aVkStructureTypevalue identifying this structure. -
pNext
public long pNext()NULLor a pointer to a structure extending this structure. -
flags
public int flags()a bitmask ofVkSubpassDescriptionFlagBitsspecifying usage of the subpass. -
pipelineBindPoint
public int pipelineBindPoint()aVkPipelineBindPointvalue specifying the pipeline type supported for this subpass. -
viewMask
public int viewMask()a bitfield of view indices describing which views rendering is broadcast to in this subpass, when multiview is enabled. -
inputAttachmentCount
public int inputAttachmentCount()the number of input attachments. -
pInputAttachments
a pointer to an array ofVkAttachmentReference2structures defining the input attachments for this subpass and their layouts. -
colorAttachmentCount
public int colorAttachmentCount()the number of color attachments. -
pColorAttachments
a pointer to an array ofcolorAttachmentCountVkAttachmentReference2structures defining the color attachments for this subpass and their layouts. -
pResolveAttachments
NULLor a pointer to an array ofcolorAttachmentCountVkAttachmentReference2structures defining the resolve attachments for this subpass and their layouts. -
pDepthStencilAttachment
a pointer to aVkAttachmentReference2structure specifying the depth/stencil attachment for this subpass and its layout. -
preserveAttachmentCount
public int preserveAttachmentCount()the number of preserved attachments. -
pPreserveAttachments
a pointer to an array ofpreserveAttachmentCountrender pass attachment indices identifying attachments that are not used by this subpass, but whose contents must be preserved throughout the subpass. -
sType
Sets the specified value to thesType()field. -
sType$Default
Sets theSTRUCTURE_TYPE_SUBPASS_DESCRIPTION_2value to thesType()field. -
pNext
Sets the specified value to thepNext()field. -
pNext
Prepends the specifiedVkFragmentShadingRateAttachmentInfoKHRvalue to thepNextchain. -
pNext
Prepends the specifiedVkMultisampledRenderToSingleSampledInfoEXTvalue to thepNextchain. -
pNext
Prepends the specifiedVkRenderPassCreationControlEXTvalue to thepNextchain. -
pNext
Prepends the specifiedVkRenderPassSubpassFeedbackCreateInfoEXTvalue to thepNextchain. -
pNext
Prepends the specifiedVkSubpassDescriptionDepthStencilResolvevalue to thepNextchain. -
pNext
Prepends the specifiedVkSubpassDescriptionDepthStencilResolveKHRvalue to thepNextchain. -
flags
Sets the specified value to theflags()field. -
pipelineBindPoint
Sets the specified value to thepipelineBindPoint()field. -
viewMask
Sets the specified value to theviewMask()field. -
pInputAttachments
Sets the address of the specifiedVkAttachmentReference2.Bufferto thepInputAttachments()field. -
colorAttachmentCount
Sets the specified value to thecolorAttachmentCount()field. -
pColorAttachments
Sets the address of the specifiedVkAttachmentReference2.Bufferto thepColorAttachments()field. -
pResolveAttachments
Sets the address of the specifiedVkAttachmentReference2.Bufferto thepResolveAttachments()field. -
pDepthStencilAttachment
Sets the address of the specifiedVkAttachmentReference2to thepDepthStencilAttachment()field. -
pPreserveAttachments
Sets the address of the specifiedIntBufferto thepPreserveAttachments()field. -
set
public VkSubpassDescription2 set(int sType, long pNext, int flags, int pipelineBindPoint, int viewMask, @Nullable VkAttachmentReference2.Buffer pInputAttachments, int colorAttachmentCount, @Nullable VkAttachmentReference2.Buffer pColorAttachments, @Nullable VkAttachmentReference2.Buffer pResolveAttachments, @Nullable VkAttachmentReference2 pDepthStencilAttachment, @Nullable IntBuffer pPreserveAttachments) 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 newVkSubpassDescription2instance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newVkSubpassDescription2instance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newVkSubpassDescription2instance allocated withBufferUtils. -
create
Returns a newVkSubpassDescription2instance for the specified memory address. -
createSafe
-
malloc
Returns a newVkSubpassDescription2.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newVkSubpassDescription2.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newVkSubpassDescription2.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aVkSubpassDescription2.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
malloc
Returns a newVkSubpassDescription2instance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newVkSubpassDescription2instance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newVkSubpassDescription2.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newVkSubpassDescription2.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
nsType
public static int nsType(long struct) Unsafe version ofsType(). -
npNext
public static long npNext(long struct) Unsafe version ofpNext(). -
nflags
public static int nflags(long struct) Unsafe version offlags(). -
npipelineBindPoint
public static int npipelineBindPoint(long struct) Unsafe version ofpipelineBindPoint(). -
nviewMask
public static int nviewMask(long struct) Unsafe version ofviewMask(). -
ninputAttachmentCount
public static int ninputAttachmentCount(long struct) Unsafe version ofinputAttachmentCount(). -
npInputAttachments
Unsafe version ofpInputAttachments(). -
ncolorAttachmentCount
public static int ncolorAttachmentCount(long struct) Unsafe version ofcolorAttachmentCount(). -
npColorAttachments
Unsafe version ofpColorAttachments(). -
npResolveAttachments
Unsafe version ofpResolveAttachments(). -
npDepthStencilAttachment
Unsafe version ofpDepthStencilAttachment(). -
npreserveAttachmentCount
public static int npreserveAttachmentCount(long struct) Unsafe version ofpreserveAttachmentCount(). -
npPreserveAttachments
Unsafe version ofpPreserveAttachments. -
nsType
public static void nsType(long struct, int value) Unsafe version ofsType. -
npNext
public static void npNext(long struct, long value) Unsafe version ofpNext. -
nflags
public static void nflags(long struct, int value) Unsafe version offlags. -
npipelineBindPoint
public static void npipelineBindPoint(long struct, int value) Unsafe version ofpipelineBindPoint. -
nviewMask
public static void nviewMask(long struct, int value) Unsafe version ofviewMask. -
ninputAttachmentCount
public static void ninputAttachmentCount(long struct, int value) Sets the specified value to theinputAttachmentCountfield of the specifiedstruct. -
npInputAttachments
Unsafe version ofpInputAttachments. -
ncolorAttachmentCount
public static void ncolorAttachmentCount(long struct, int value) Sets the specified value to thecolorAttachmentCountfield of the specifiedstruct. -
npColorAttachments
Unsafe version ofpColorAttachments. -
npResolveAttachments
Unsafe version ofpResolveAttachments. -
npDepthStencilAttachment
Unsafe version ofpDepthStencilAttachment. -
npreserveAttachmentCount
public static void npreserveAttachmentCount(long struct, int value) Sets the specified value to thepreserveAttachmentCountfield of the specifiedstruct. -
npPreserveAttachments
Unsafe version ofpPreserveAttachments. -
validate
public static void validate(long struct) Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-