Class EXTColorWriteEnable
- java.lang.Object
-
- org.lwjgl.vulkan.EXTColorWriteEnable
-
public class EXTColorWriteEnable extends java.lang.ObjectThis extension allows for selectively enabling and disabling writes to output color attachments via a pipeline dynamic state.The intended use cases for this new state are mostly identical to those of colorWriteMask, such as selectively disabling writes to avoid feedback loops between subpasses or bandwidth savings for unused outputs. By making the state dynamic, one additional benefit is the ability to reduce pipeline counts and pipeline switching via shaders that write a superset of the desired data of which subsets are selected dynamically. The reason for a new state, colorWriteEnable, rather than making colorWriteMask dynamic is that, on many implementations, the more flexible per-component semantics of the colorWriteMask state cannot be made dynamic in a performant manner.
VK_EXT_color_write_enable
- Name String
VK_EXT_color_write_enable- Extension Type
- Device extension
- Registered Extension Number
- 382
- Revision
- 1
- Extension and Version Dependencies
- Requires Vulkan 1.0
- Requires
VK_KHR_get_physical_device_properties2
- Contact
- Sharif Elcott selcott
Other Extension Metadata
- Last Modified Date
- 2020-02-25
- IP Status
- No known IP claims.
- Contributors
- Sharif Elcott, Google
- Tobias Hector, AMD
- Piers Daniell, NVIDIA
-
-
Field Summary
Fields Modifier and Type Field Description static intVK_DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXTExtendsVkDynamicState.static java.lang.StringVK_EXT_COLOR_WRITE_ENABLE_EXTENSION_NAMEThe extension name.static intVK_EXT_COLOR_WRITE_ENABLE_SPEC_VERSIONThe extension specification version.static intVK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COLOR_WRITE_ENABLE_FEATURES_EXT
VK_STRUCTURE_TYPE_PIPELINE_COLOR_WRITE_CREATE_INFO_EXTExtendsVkStructureType.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidnvkCmdSetColorWriteEnableEXT(org.lwjgl.vulkan.VkCommandBuffer commandBuffer, int attachmentCount, long pColorWriteEnables)Unsafe version of:CmdSetColorWriteEnableEXTstatic voidvkCmdSetColorWriteEnableEXT(org.lwjgl.vulkan.VkCommandBuffer commandBuffer, int[] pColorWriteEnables)Array version of:CmdSetColorWriteEnableEXTstatic voidvkCmdSetColorWriteEnableEXT(org.lwjgl.vulkan.VkCommandBuffer commandBuffer, java.nio.IntBuffer pColorWriteEnables)Enable or disable writes to a color attachment dynamically for a command buffer.
-
-
-
Field Detail
-
VK_EXT_COLOR_WRITE_ENABLE_SPEC_VERSION
The extension specification version.
-
VK_EXT_COLOR_WRITE_ENABLE_EXTENSION_NAME
The extension name.
-
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COLOR_WRITE_ENABLE_FEATURES_EXT, VK_STRUCTURE_TYPE_PIPELINE_COLOR_WRITE_CREATE_INFO_EXT
ExtendsVkStructureType.Enum values:
-
VK_DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXT
ExtendsVkDynamicState.
-
-
Method Detail
-
nvkCmdSetColorWriteEnableEXT
public static void nvkCmdSetColorWriteEnableEXT(org.lwjgl.vulkan.VkCommandBuffer commandBuffer, int attachmentCount, long pColorWriteEnables)Unsafe version of:CmdSetColorWriteEnableEXT- Parameters:
attachmentCount- the number ofVkBool32elements inpColorWriteEnables.
-
vkCmdSetColorWriteEnableEXT
public static void vkCmdSetColorWriteEnableEXT(org.lwjgl.vulkan.VkCommandBuffer commandBuffer, java.nio.IntBuffer pColorWriteEnables)Enable or disable writes to a color attachment dynamically for a command buffer.C Specification
To dynamically enable or disable writes to a color attachment, call:
void vkCmdSetColorWriteEnableEXT( VkCommandBuffer commandBuffer, uint32_t attachmentCount, const VkBool32* pColorWriteEnables);Description
This command sets the color write enables for subsequent drawing commands when the graphics pipeline is created with
DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXTset inVkPipelineDynamicStateCreateInfo::pDynamicStates. Otherwise, this state is specified by theVkPipelineColorWriteCreateInfoEXT::pColorWriteEnablesvalues used to create the currently active pipeline.Valid Usage
- The colorWriteEnable feature must be enabled
attachmentCountmust be equal to theattachmentCountmember of theVkPipelineColorBlendStateCreateInfostructure specified during pipeline creation
Valid Usage (Implicit)
commandBuffermust be a validVkCommandBufferhandlepColorWriteEnablesmust be a valid pointer to an array ofattachmentCountVkBool32valuescommandBuffermust be in the recording state- The
VkCommandPoolthatcommandBufferwas allocated from must support graphics operations attachmentCountmust be greater than 0
Host Synchronization
- Host access to
commandBuffermust be externally synchronized - Host access to the
VkCommandPoolthatcommandBufferwas allocated from must be externally synchronized
Command Properties
Command Buffer Levels Render Pass Scope Supported Queue Types Primary Secondary Both Graphics - Parameters:
commandBuffer- the command buffer into which the command will be recorded.pColorWriteEnables- a pointer to an array of per target attachment boolean values specifying whether color writes are enabled for the given attachment.
-
vkCmdSetColorWriteEnableEXT
public static void vkCmdSetColorWriteEnableEXT(org.lwjgl.vulkan.VkCommandBuffer commandBuffer, int[] pColorWriteEnables)Array version of:CmdSetColorWriteEnableEXT
-
-