| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Vulkan.Extensions.VK_EXT_custom_resolve
Description
Name
VK_EXT_custom_resolve - device extension
VK_EXT_custom_resolve
- Name String
VK_EXT_custom_resolve
- Extension Type
- Device extension
- Registered Extension Number
- 629
- Revision
- 1
- Ratification Status
- Ratified
- Extension and Version Dependencies
- VK_KHR_get_physical_device_properties2 or Vulkan Version 1.1
- API Interactions
- Interacts with VK_VERSION_1_3
- Interacts with VK_KHR_dynamic_rendering
- Contact
- Extension Proposal
- VK_EXT_custom_resolve
Other Extension Metadata
- Last Modified Date
- 2025-05-13
- IP Status
- No known IP claims.
- Interactions and External Dependencies
- This extension interacts with
VK_KHR_dynamic_rendering - This extension interacts with
VK_EXT_dynamic_rendering_unused_attachments - This extension interacts with
VK_EXT_fragment_density_map - This extension interacts with
VK_EXT_graphics_pipeline_library - This extension interacts with
VK_EXT_shader_object
- This extension interacts with
- Contributors
- Mike Blumenkrantz, Valve
- Connor Abbott, Valve
- Samuel Pitoiset, Valve
- Matthew Netsch, Qualcomm
- Jan-Harald Fredriksen, ARM
- Ting Wei, ARM
- Ricardo Garcia, Igalia
- Spencer Fricke, LunarG
- Piers Daniell, Nvidia
Description
This extension provides functionality for using shaders to resolve multisample rendering attachments.
It builds upon mechanics introduced by VK_QCOM_render_pass_shader_resolve, additionally adding support for dynamic rendering.
New Commands
If VK_KHR_dynamic_rendering or Vulkan Version 1.3 is supported:
New Structures
If VK_KHR_dynamic_rendering or Vulkan Version 1.3 is supported:
BeginCustomResolveInfoEXTExtending
GraphicsPipelineCreateInfo,CommandBufferInheritanceInfo,ShaderCreateInfoEXT:
New Enum Constants
EXT_CUSTOM_RESOLVE_SPEC_VERSIONExtending
StructureType:Extending
SubpassDescriptionFlagBits:
If VK_KHR_dynamic_rendering or Vulkan Version 1.3 is supported:
Extending
RenderingFlagBits:Extending
ResolveModeFlagBits:Extending
StructureType:
Issues
1) How will this work with shader objects?
Some vendors emit an epilog at the end of the FS that stores each color/depth/stencil attachment to the appropriate tilebuffer location, and to do that they need to know the layout of the tilebuffer which depends on the attachment formats/sample counts. We agreed that for shader object the FS epilog is emitted dynamically when the draw happens.
Version History
Revision 1, 2025-05-13 (Mike Blumenkrantz)
- Initial draft
See Also
No cross-references are available
Document Notes
For more information, see the Vulkan Specification.
This page is a generated document. Fixes and changes should be made to the generator scripts, not directly.
Synopsis
- cmdBeginCustomResolveEXT :: MonadIO io => CommandBuffer -> ("beginCustomResolveInfo" ::: Maybe BeginCustomResolveInfoEXT) -> io ()
- data BeginCustomResolveInfoEXT = BeginCustomResolveInfoEXT
- data PhysicalDeviceCustomResolveFeaturesEXT = PhysicalDeviceCustomResolveFeaturesEXT {}
- data CustomResolveCreateInfoEXT = CustomResolveCreateInfoEXT {}
- type EXT_CUSTOM_RESOLVE_SPEC_VERSION = 1
- pattern EXT_CUSTOM_RESOLVE_SPEC_VERSION :: Integral a => a
- type EXT_CUSTOM_RESOLVE_EXTENSION_NAME = "VK_EXT_custom_resolve"
- pattern EXT_CUSTOM_RESOLVE_EXTENSION_NAME :: (Eq a, IsString a) => a
Documentation
cmdBeginCustomResolveEXT Source #
Arguments
| :: MonadIO io | |
| => CommandBuffer |
|
| -> ("beginCustomResolveInfo" ::: Maybe BeginCustomResolveInfoEXT) |
|
| -> io () |
vkCmdBeginCustomResolveEXT - Begins a shader resolve operation
Description
Following this call, any resolveImageView with resolveMode set to
RESOLVE_MODE_CUSTOM_BIT_EXT
will be written by outputs which would otherwise have written to the
imageView image until the end of the current render pass instance.
Following this call, the fragment area may be reduced to (1,1) if a fragment density map is attached. If this occurs, reads of input attachments mapped to a color, depth, or stencil attachment return the value for the original larger fragment containing the smaller fragment. Reads of input attachments not mapped to a color, depth, or stencil attachment use the new fragment area.
Because the content of any depth/stencil resolve attachment as well as any color resolve attachment is undefined at the beginning of a resolve operation, any depth testing, stencil testing, or blending operation which sources these undefined values also has undefined result value.
During a custom resolve pass, multiple fragment invocations writing to the same (x, y, layer, view, sample) coordinate, i.e. overdraw, will produce undefined behavior.
Implementations are allowed to implement custom resolve attachment writes through other mechanisms than framebuffer attachment writes, which would normally obey rules of rasterization order.
Valid Usage
- The current
render pass instance must have been started or resumed by
cmdBeginRenderingin thiscommandBuffer
-
cmdBeginCustomResolveEXTmust not have already been recorded in the current render pass instance - The current render pass
instance must have specified
RENDERING_CUSTOM_RESOLVE_BIT_EXT - The current render pass
instance must not have specified
RENDERING_SUSPENDING_BIT
Valid Usage (Implicit)
-
commandBuffermust be a validCommandBufferhandle
-
If
pBeginCustomResolveInfois notNULL,pBeginCustomResolveInfomust be a valid pointer to a validBeginCustomResolveInfoEXTstructure -
commandBuffermust be in the recording state - The
CommandPoolthatcommandBufferwas allocated from must supportQUEUE_GRAPHICS_BIToperations - This command must only be called inside of a render pass instance
- This command must not be called between suspended render pass instances
- This command must only be called outside of a video coding scope
Host Synchronization
- Host access to
commandBuffermust be externally synchronized
- Host access to the
CommandPoolthatcommandBufferwas allocated from must be externally synchronized
Command Properties
'
| Command Buffer Levels | Render Pass Scope | Video Coding Scope | Supported Queue Types | Command Type |
|---|---|---|---|---|
| Primary Secondary | Inside | Outside | VK_QUEUE_GRAPHICS_BIT | Action |
Conditional Rendering
vkCmdBeginCustomResolveEXT is affected by conditional rendering
See Also
VK_EXT_custom_resolve,
VK_KHR_dynamic_rendering,
VK_VERSION_1_3,
BeginCustomResolveInfoEXT, CommandBuffer
data BeginCustomResolveInfoEXT Source #
VkBeginCustomResolveInfoEXT - Structure specifying shader resolve information
Valid Usage (Implicit)
See Also
VK_EXT_custom_resolve,
VK_KHR_dynamic_rendering,
VK_VERSION_1_3,
StructureType,
cmdBeginCustomResolveEXT
Constructors
| BeginCustomResolveInfoEXT |
Instances
data PhysicalDeviceCustomResolveFeaturesEXT Source #
VkPhysicalDeviceCustomResolveFeaturesEXT - Structure indicating support for shader resolves
Members
This structure describes the following feature:
Description
If the PhysicalDeviceCustomResolveFeaturesEXT structure is included in
the pNext chain of the
PhysicalDeviceFeatures2
structure passed to
getPhysicalDeviceFeatures2,
it is filled in to indicate whether each corresponding feature is
supported. If the application wishes to use a
Device with any features described by
PhysicalDeviceCustomResolveFeaturesEXT, it must add an instance of
the structure, with the desired feature members set to
TRUE, to the pNext chain of
DeviceCreateInfo when creating the
Device.
Valid Usage (Implicit)
See Also
Constructors
| PhysicalDeviceCustomResolveFeaturesEXT | |
Fields | |
Instances
data CustomResolveCreateInfoEXT Source #
VkCustomResolveCreateInfoEXT - Structure specifying format info for custom resolves
Description
If the pNext chain includes this structure for one of:
- a
GraphicsPipelineCreateInfofor a pipeline created without aRenderPass - a
CommandBufferInheritanceInfofor a secondary command buffer within a render pass instance begun withcmdBeginRendering.
it specifies the formats used in custom resolves within the same render pass. It also specifies that the corresponding object will be used in a render pass which contains a custom resolve operation.
If the pNext chain includes this structure for a
ShaderCreateInfoEXT for a
fragment shader object, it only specifies that the fragment shader will
be used in a custom resolve operation.
If a graphics pipeline is created with a valid
RenderPass, parameters of this structure are
ignored.
If customResolve is FALSE, the
pipeline can only be used outside the custom resolve section. If
customResolve is TRUE, the pipeline
can only be used inside the custom resolve section.
When a dynamic render pass instance contains a custom resolve operation and the dynamicRenderingUnusedAttachments feature is not enabled , all pipelines used to draw in such render pass must include this structure and have identical format information in it. When a dynamic render pass does not contain a custom resolve operation and the dynamicRenderingUnusedAttachments feature is not enabled , all pipelines used to draw in such render pass must not include this structure.
If the
dynamicRenderingUnusedAttachments
feature is enabled, then when this structure is not included in the
pNext chain for
GraphicsPipelineCreateInfo,
customResolve is FALSE,
colorAttachmentCount is 0, and depthAttachmentFormat and
stencilAttachmentFormat are
FORMAT_UNDEFINED.
If depthAttachmentFormat, stencilAttachmentFormat, or any element of
pColorAttachmentFormats is
FORMAT_UNDEFINED, it indicates that the
corresponding attachment is unused within the resolve portion of the
render pass. Valid formats indicate that an attachment can be used -
but it is still valid to set the attachment to NULL when beginning
rendering.
When passed as a pNext member to a
ShaderCreateInfoEXT struct for
use with fragment density maps, the colorAttachmentCount,
pColorAttachmentFormats, depthAttachmentFormat, and
stencilAttachmentFormat members of this struct are ignored. When not
passed as a pNext member, customResolve is
FALSE.
Valid Usage
-
colorAttachmentCountmust be less than or equal to maxColorAttachments
- If
depthAttachmentFormatis notFORMAT_UNDEFINED, it must be a format that includes a depth component - If
depthAttachmentFormatis notFORMAT_UNDEFINED, it must be a format with potential format features that includeFORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT - If
any element of
pColorAttachmentFormatsis notFORMAT_UNDEFINED, it must be a format with potential format features that includeFORMAT_FEATURE_COLOR_ATTACHMENT_BIT, orFORMAT_FEATURE_2_LINEAR_COLOR_ATTACHMENT_BIT_NVif the linearColorAttachment feature is enabled - If
stencilAttachmentFormatis notFORMAT_UNDEFINED, it must be a format that includes a stencil aspect - If
stencilAttachmentFormatis notFORMAT_UNDEFINED, it must be a format with potential format features that includeFORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT - If
depthAttachmentFormatis notFORMAT_UNDEFINEDandstencilAttachmentFormatis notFORMAT_UNDEFINED,depthAttachmentFormatmust equalstencilAttachmentFormat
Valid Usage (Implicit)
-
sTypemust beSTRUCTURE_TYPE_CUSTOM_RESOLVE_CREATE_INFO_EXT
See Also
VK_EXT_custom_resolve,
VK_KHR_dynamic_rendering,
VK_VERSION_1_3,
Bool32,
Format,
StructureType
Constructors
| CustomResolveCreateInfoEXT | |
Fields
| |
Instances
type EXT_CUSTOM_RESOLVE_SPEC_VERSION = 1 Source #
pattern EXT_CUSTOM_RESOLVE_SPEC_VERSION :: Integral a => a Source #
type EXT_CUSTOM_RESOLVE_EXTENSION_NAME = "VK_EXT_custom_resolve" Source #
pattern EXT_CUSTOM_RESOLVE_EXTENSION_NAME :: (Eq a, IsString a) => a Source #