Vulkan Logo

32. Device-Generated Commands

This chapter discusses the generation of command buffer content on the device, for which these principle steps are to be taken:

vkCmdPreprocessGeneratedCommandsNV executes in a separate logical pipeline from either graphics or compute. When preprocessing commands in a separate step they must be explicitly synchronized against the command execution. When not preprocessing, the preprocessing is automatically synchronized against the command execution.

32.1. Indirect Commands Layout

The device-side command generation happens through an iterative processing of an atomic sequence comprised of command tokens, which are represented by:

// Provided by VK_NV_device_generated_commands
VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkIndirectCommandsLayoutNV)

32.1.1. Creation and Deletion

Indirect command layouts are created by:

// Provided by VK_NV_device_generated_commands
VkResult vkCreateIndirectCommandsLayoutNV(
    VkDevice                                    device,
    const VkIndirectCommandsLayoutCreateInfoNV* pCreateInfo,
    const VkAllocationCallbacks*                pAllocator,
    VkIndirectCommandsLayoutNV*                 pIndirectCommandsLayout);
  • device is the logical device that creates the indirect command layout.

  • pCreateInfo is a pointer to a VkIndirectCommandsLayoutCreateInfoNV structure containing parameters affecting creation of the indirect command layout.

  • pAllocator controls host memory allocation as described in the Memory Allocation chapter.

  • pIndirectCommandsLayout is a pointer to a VkIndirectCommandsLayoutNV handle in which the resulting indirect command layout is returned.

Valid Usage
Valid Usage (Implicit)
  • VUID-vkCreateIndirectCommandsLayoutNV-device-parameter
    device must be a valid VkDevice handle

  • VUID-vkCreateIndirectCommandsLayoutNV-pCreateInfo-parameter
    pCreateInfo must be a valid pointer to a valid VkIndirectCommandsLayoutCreateInfoNV structure

  • VUID-vkCreateIndirectCommandsLayoutNV-pAllocator-parameter
    If pAllocator is not NULL, pAllocator must be a valid pointer to a valid VkAllocationCallbacks structure

  • VUID-vkCreateIndirectCommandsLayoutNV-pIndirectCommandsLayout-parameter
    pIndirectCommandsLayout must be a valid pointer to a VkIndirectCommandsLayoutNV handle

Return Codes
Success
  • VK_SUCCESS

Failure
  • VK_ERROR_OUT_OF_HOST_MEMORY

  • VK_ERROR_OUT_OF_DEVICE_MEMORY

The VkIndirectCommandsLayoutCreateInfoNV structure is defined as:

// Provided by VK_NV_device_generated_commands
typedef struct VkIndirectCommandsLayoutCreateInfoNV {
    VkStructureType                           sType;
    const void*                               pNext;
    VkIndirectCommandsLayoutUsageFlagsNV      flags;
    VkPipelineBindPoint                       pipelineBindPoint;
    uint32_t                                  tokenCount;
    const VkIndirectCommandsLayoutTokenNV*    pTokens;
    uint32_t                                  streamCount;
    const uint32_t*                           pStreamStrides;
} VkIndirectCommandsLayoutCreateInfoNV;

The following code illustrates some of the flags:

void cmdProcessAllSequences(cmd, pipeline, indirectCommandsLayout, pIndirectCommandsTokens, sequencesCount, indexbuffer, indexbufferOffset)
{
  for (s = 0; s < sequencesCount; s++)
  {
    sUsed = s;

    if (indirectCommandsLayout.flags & VK_INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV) {
      sUsed = indexbuffer.load_uint32( sUsed * sizeof(uint32_t) + indexbufferOffset);
    }

    if (indirectCommandsLayout.flags & VK_INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV) {
      sUsed = incoherent_implementation_dependent_permutation[ sUsed ];
    }

    cmdProcessSequence( cmd, pipeline, indirectCommandsLayout, pIndirectCommandsTokens, sUsed );
  }
}

When tokens are consumed, an offset is computed based on token offset and stream stride. The resulting offset is required to be aligned. The alignment for a specific token is equal to the scalar alignment of the data type as defined in Alignment Requirements, or VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::minIndirectCommandsBufferOffsetAlignment, whichever is lower.

Note

A minIndirectCommandsBufferOffsetAlignment of 4 allows VkDeviceAddress to be packed as uvec2 with scalar layout instead of uint64_t with 8 byte alignment. This enables direct compatibility with D3D12 command signature layouts.

Valid Usage
  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pipelineBindPoint-02930
    The pipelineBindPoint must be VK_PIPELINE_BIND_POINT_GRAPHICS

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-tokenCount-02931
    tokenCount must be greater than 0 and less than or equal to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::maxIndirectCommandsTokenCount

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pTokens-02932
    If pTokens contains an entry of VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV it must be the first element of the array and there must be only a single element of such token type

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pTokens-02933
    If pTokens contains an entry of VK_INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV there must be only a single element of such token type

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pTokens-02934
    All state tokens in pTokens must occur before any work provoking tokens (VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV, VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV, VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV, VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_MESH_TASKS_NV )

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pTokens-02935
    The content of pTokens must include one single work provoking token that is compatible with the pipelineBindPoint

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-streamCount-02936
    streamCount must be greater than 0 and less or equal to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::maxIndirectCommandsStreamCount

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pStreamStrides-02937
    each element of pStreamStrides must be greater than `0`and less than or equal to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::maxIndirectCommandsStreamStride. Furthermore the alignment of each token input must be ensured

Valid Usage (Implicit)
  • VUID-VkIndirectCommandsLayoutCreateInfoNV-sType-sType
    sType must be VK_STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_NV

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pNext-pNext
    pNext must be NULL

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-flags-parameter
    flags must be a valid combination of VkIndirectCommandsLayoutUsageFlagBitsNV values

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pipelineBindPoint-parameter
    pipelineBindPoint must be a valid VkPipelineBindPoint value

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pTokens-parameter
    pTokens must be a valid pointer to an array of tokenCount valid VkIndirectCommandsLayoutTokenNV structures

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-pStreamStrides-parameter
    pStreamStrides must be a valid pointer to an array of streamCount uint32_t values

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-tokenCount-arraylength
    tokenCount must be greater than 0

  • VUID-VkIndirectCommandsLayoutCreateInfoNV-streamCount-arraylength
    streamCount must be greater than 0

Bits which can be set in VkIndirectCommandsLayoutCreateInfoNV::flags, specifying usage hints of an indirect command layout, are:

// Provided by VK_NV_device_generated_commands
typedef enum VkIndirectCommandsLayoutUsageFlagBitsNV {
    VK_INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV = 0x00000001,
    VK_INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV = 0x00000002,
    VK_INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV = 0x00000004,
} VkIndirectCommandsLayoutUsageFlagBitsNV;
  • VK_INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV specifies that the layout is always used with the manual preprocessing step through calling vkCmdPreprocessGeneratedCommandsNV and executed by vkCmdExecuteGeneratedCommandsNV with isPreprocessed set to VK_TRUE.

  • VK_INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV specifies that the input data for the sequences is not implicitly indexed from 0..sequencesUsed but a user provided VkBuffer encoding the index is provided.

  • VK_INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV specifies that the processing of sequences can happen at an implementation-dependent order, which is not: guaranteed to be coherent using the same input data.

// Provided by VK_NV_device_generated_commands
typedef VkFlags VkIndirectCommandsLayoutUsageFlagsNV;

VkIndirectCommandsLayoutUsageFlagsNV is a bitmask type for setting a mask of zero or more VkIndirectCommandsLayoutUsageFlagBitsNV.

Indirect command layouts are destroyed by:

// Provided by VK_NV_device_generated_commands
void vkDestroyIndirectCommandsLayoutNV(
    VkDevice                                    device,
    VkIndirectCommandsLayoutNV                  indirectCommandsLayout,
    const VkAllocationCallbacks*                pAllocator);
  • device is the logical device that destroys the layout.

  • indirectCommandsLayout is the layout to destroy.

  • pAllocator controls host memory allocation as described in the Memory Allocation chapter.

Valid Usage
  • VUID-vkDestroyIndirectCommandsLayoutNV-indirectCommandsLayout-02938
    All submitted commands that refer to indirectCommandsLayout must have completed execution

  • VUID-vkDestroyIndirectCommandsLayoutNV-indirectCommandsLayout-02939
    If VkAllocationCallbacks were provided when indirectCommandsLayout was created, a compatible set of callbacks must be provided here

  • VUID-vkDestroyIndirectCommandsLayoutNV-indirectCommandsLayout-02940
    If no VkAllocationCallbacks were provided when indirectCommandsLayout was created, pAllocator must be NULL

  • VUID-vkDestroyIndirectCommandsLayoutNV-deviceGeneratedCommands-02941
    The VkPhysicalDeviceDeviceGeneratedCommandsFeaturesNV::deviceGeneratedCommands feature must be enabled

Valid Usage (Implicit)
  • VUID-vkDestroyIndirectCommandsLayoutNV-device-parameter
    device must be a valid VkDevice handle

  • VUID-vkDestroyIndirectCommandsLayoutNV-indirectCommandsLayout-parameter
    If indirectCommandsLayout is not VK_NULL_HANDLE, indirectCommandsLayout must be a valid VkIndirectCommandsLayoutNV handle

  • VUID-vkDestroyIndirectCommandsLayoutNV-pAllocator-parameter
    If pAllocator is not NULL, pAllocator must be a valid pointer to a valid VkAllocationCallbacks structure

  • VUID-vkDestroyIndirectCommandsLayoutNV-indirectCommandsLayout-parent
    If indirectCommandsLayout is a valid handle, it must have been created, allocated, or retrieved from device

Host Synchronization
  • Host access to indirectCommandsLayout must be externally synchronized

32.1.2. Token Input Streams

The VkIndirectCommandsStreamNV structure specifies the input data for one or more tokens at processing time.

// Provided by VK_NV_device_generated_commands
typedef struct VkIndirectCommandsStreamNV {
    VkBuffer        buffer;
    VkDeviceSize    offset;
} VkIndirectCommandsStreamNV;
  • buffer specifies the VkBuffer storing the functional arguments for each sequence. These arguments can be written by the device.

  • offset specified an offset into buffer where the arguments start.

Valid Usage
  • VUID-VkIndirectCommandsStreamNV-buffer-02942
    The buffer’s usage flag must have the VK_BUFFER_USAGE_INDIRECT_BUFFER_BIT bit set

  • VUID-VkIndirectCommandsStreamNV-offset-02943
    The offset must be aligned to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::minIndirectCommandsBufferOffsetAlignment

  • VUID-VkIndirectCommandsStreamNV-buffer-02975
    If buffer is non-sparse then it must be bound completely and contiguously to a single VkDeviceMemory object

Valid Usage (Implicit)
  • VUID-VkIndirectCommandsStreamNV-buffer-parameter
    buffer must be a valid VkBuffer handle

The input streams can contain raw uint32_t values, existing indirect commands such as:

or additional commands as listed below. How the data is used is described in the next section.

The VkBindShaderGroupIndirectCommandNV structure specifies the input data for the VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV token.

// Provided by VK_NV_device_generated_commands
typedef struct VkBindShaderGroupIndirectCommandNV {
    uint32_t    groupIndex;
} VkBindShaderGroupIndirectCommandNV;
  • groupIndex specifies which shader group of the current bound graphics pipeline is used.

Valid Usage
  • VUID-VkBindShaderGroupIndirectCommandNV-None-02944
    The current bound graphics pipeline, as well as the pipelines it may reference, must have been created with VK_PIPELINE_CREATE_INDIRECT_BINDABLE_BIT_NV

  • VUID-VkBindShaderGroupIndirectCommandNV-index-02945
    The index must be within range of the accessible shader groups of the current bound graphics pipeline. See vkCmdBindPipelineShaderGroupNV for further details

The VkBindIndexBufferIndirectCommandNV structure specifies the input data for the VK_INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV token.

// Provided by VK_NV_device_generated_commands
typedef struct VkBindIndexBufferIndirectCommandNV {
    VkDeviceAddress    bufferAddress;
    uint32_t           size;
    VkIndexType        indexType;
} VkBindIndexBufferIndirectCommandNV;
  • bufferAddress specifies a physical address of the VkBuffer used as index buffer.

  • size is the byte size range which is available for this operation from the provided address.

  • indexType is a VkIndexType value specifying how indices are treated. Instead of the Vulkan enum values, a custom uint32_t value can be mapped to an VkIndexType by specifying the VkIndirectCommandsLayoutTokenNV::pIndexTypes and VkIndirectCommandsLayoutTokenNV::pIndexTypeValues arrays.

Valid Usage
  • VUID-VkBindIndexBufferIndirectCommandNV-None-02946
    The buffer’s usage flag from which the address was acquired must have the VK_BUFFER_USAGE_INDEX_BUFFER_BIT bit set

  • VUID-VkBindIndexBufferIndirectCommandNV-bufferAddress-02947
    The bufferAddress must be aligned to the indexType used

  • VUID-VkBindIndexBufferIndirectCommandNV-None-02948
    Each element of the buffer from which the address was acquired and that is non-sparse must be bound completely and contiguously to a single VkDeviceMemory object

Valid Usage (Implicit)
  • VUID-VkBindIndexBufferIndirectCommandNV-indexType-parameter
    indexType must be a valid VkIndexType value

The VkBindVertexBufferIndirectCommandNV structure specifies the input data for the VK_INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV token.

// Provided by VK_NV_device_generated_commands
typedef struct VkBindVertexBufferIndirectCommandNV {
    VkDeviceAddress    bufferAddress;
    uint32_t           size;
    uint32_t           stride;
} VkBindVertexBufferIndirectCommandNV;
  • bufferAddress specifies a physical address of the VkBuffer used as vertex input binding.

  • size is the byte size range which is available for this operation from the provided address.

  • stride is the byte size stride for this vertex input binding as in VkVertexInputBindingDescription::stride. It is only used if VkIndirectCommandsLayoutTokenNV::vertexDynamicStride was set, otherwise the stride is inherited from the current bound graphics pipeline.

Valid Usage
  • VUID-VkBindVertexBufferIndirectCommandNV-None-02949
    The buffer’s usage flag from which the address was acquired must have the VK_BUFFER_USAGE_VERTEX_BUFFER_BIT bit set

  • VUID-VkBindVertexBufferIndirectCommandNV-None-02950
    Each element of the buffer from which the address was acquired and that is non-sparse must be bound completely and contiguously to a single VkDeviceMemory object

The VkSetStateFlagsIndirectCommandNV structure specifies the input data for the VK_INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV token. Which state is changed depends on the VkIndirectStateFlagBitsNV specified at VkIndirectCommandsLayoutNV creation time.

// Provided by VK_NV_device_generated_commands
typedef struct VkSetStateFlagsIndirectCommandNV {
    uint32_t    data;
} VkSetStateFlagsIndirectCommandNV;
  • data encodes packed state that this command alters.

    • Bit 0: If set represents VK_FRONT_FACE_CLOCKWISE, otherwise VK_FRONT_FACE_COUNTER_CLOCKWISE

A subset of the graphics pipeline state can be altered using indirect state flags:

// Provided by VK_NV_device_generated_commands
typedef enum VkIndirectStateFlagBitsNV {
    VK_INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV = 0x00000001,
} VkIndirectStateFlagBitsNV;
  • VK_INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV allows to toggle the VkFrontFace rasterization state for subsequent draw operations.

// Provided by VK_NV_device_generated_commands
typedef VkFlags VkIndirectStateFlagsNV;

VkIndirectStateFlagsNV is a bitmask type for setting a mask of zero or more VkIndirectStateFlagBitsNV.

The VkBindPipelineIndirectCommandNV structure specifies the input data for the VK_INDIRECT_COMMANDS_TOKEN_TYPE_PIPELINE_NV token.

// Provided by VK_NV_device_generated_commands_compute
typedef struct VkBindPipelineIndirectCommandNV {
    VkDeviceAddress    pipelineAddress;
} VkBindPipelineIndirectCommandNV;
  • pipelineAddress specifies the pipeline address of the compute pipeline that will be used in device generated rendering.

Valid Usage

32.1.3. Tokenized Command Processing

The processing is in principle illustrated below:

void cmdProcessSequence(cmd, pipeline, indirectCommandsLayout, pIndirectCommandsStreams, s)
{
  for (t = 0; t < indirectCommandsLayout.tokenCount; t++)
  {
    uint32_t stream  = indirectCommandsLayout.pTokens[t].stream;
    uint32_t offset  = indirectCommandsLayout.pTokens[t].offset;
    uint32_t stride  = indirectCommandsLayout.pStreamStrides[stream];
    stream            = pIndirectCommandsStreams[stream];
    const void* input = stream.buffer.pointer( stream.offset + stride * s + offset )

    // further details later
    indirectCommandsLayout.pTokens[t].command (cmd, pipeline, input, s);
  }
}

void cmdProcessAllSequences(cmd, pipeline, indirectCommandsLayout, pIndirectCommandsStreams, sequencesCount)
{
  for (s = 0; s < sequencesCount; s++)
  {
    cmdProcessSequence(cmd, pipeline, indirectCommandsLayout, pIndirectCommandsStreams, s);
  }
}

The processing of each sequence is considered stateless, therefore all state changes must occur prior work provoking commands within the sequence. A single sequence is strictly targeting the VkPipelineBindPoint it was created with.

The primary input data for each token is provided through VkBuffer content at preprocessing using vkCmdPreprocessGeneratedCommandsNV or execution time using vkCmdExecuteGeneratedCommandsNV, however some functional arguments, for example binding sets, are specified at layout creation time. The input size is different for each token.

Possible values of those elements of the VkIndirectCommandsLayoutCreateInfoNV::pTokens array specifying command tokens (other elements of the array specify command parameters) are:

// Provided by VK_NV_device_generated_commands
typedef enum VkIndirectCommandsTokenTypeNV {
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV = 0,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV = 1,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV = 2,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV = 3,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV = 4,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV = 5,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV = 6,
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV = 7,
  // Provided by VK_EXT_mesh_shader with VK_NV_device_generated_commands
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_MESH_TASKS_NV = 1000328000,
  // Provided by VK_NV_device_generated_commands_compute
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_PIPELINE_NV = 1000428003,
  // Provided by VK_NV_device_generated_commands_compute
    VK_INDIRECT_COMMANDS_TOKEN_TYPE_DISPATCH_NV = 1000428004,
} VkIndirectCommandsTokenTypeNV;
Table 45. Supported indirect command tokens
Token type Equivalent command

VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV

vkCmdBindPipelineShaderGroupNV

VK_INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV

-

VK_INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV

vkCmdBindIndexBuffer

VK_INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV

vkCmdBindVertexBuffers

VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV

vkCmdPushConstants

VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV

vkCmdDrawIndexedIndirect

VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV

vkCmdDrawIndirect

VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV

vkCmdDrawMeshTasksIndirectNV

VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_MESH_TASKS_NV

vkCmdDrawMeshTasksIndirectEXT

The VkIndirectCommandsLayoutTokenNV structure specifies details to the function arguments that need to be known at layout creation time:

// Provided by VK_NV_device_generated_commands
typedef struct VkIndirectCommandsLayoutTokenNV {
    VkStructureType                  sType;
    const void*                      pNext;
    VkIndirectCommandsTokenTypeNV    tokenType;
    uint32_t                         stream;
    uint32_t                         offset;
    uint32_t                         vertexBindingUnit;
    VkBool32                         vertexDynamicStride;
    VkPipelineLayout                 pushconstantPipelineLayout;
    VkShaderStageFlags               pushconstantShaderStageFlags;
    uint32_t                         pushconstantOffset;
    uint32_t                         pushconstantSize;
    VkIndirectStateFlagsNV           indirectStateFlags;
    uint32_t                         indexTypeCount;
    const VkIndexType*               pIndexTypes;
    const uint32_t*                  pIndexTypeValues;
} VkIndirectCommandsLayoutTokenNV;
  • sType is a VkStructureType value identifying this structure.

  • pNext is NULL or a pointer to a structure extending this structure.

  • tokenType specifies the token command type.

  • stream is the index of the input stream containing the token argument data.

  • offset is a relative starting offset within the input stream memory for the token argument data.

  • vertexBindingUnit is used for the vertex buffer binding command.

  • vertexDynamicStride sets if the vertex buffer stride is provided by the binding command rather than the current bound graphics pipeline state.

  • pushconstantPipelineLayout is the VkPipelineLayout used for the push constant command.

  • pushconstantShaderStageFlags are the shader stage flags used for the push constant command.

  • pushconstantOffset is the offset used for the push constant command.

  • pushconstantSize is the size used for the push constant command.

  • indirectStateFlags are the active states for the state flag command.

  • indexTypeCount is the optional size of the pIndexTypes and pIndexTypeValues array pairings. If not zero, it allows to register a custom uint32_t value to be treated as specific VkIndexType.

  • pIndexTypes is the used VkIndexType for the corresponding uint32_t value entry in pIndexTypeValues.

Valid Usage
  • VUID-VkIndirectCommandsLayoutTokenNV-stream-02951
    stream must be smaller than VkIndirectCommandsLayoutCreateInfoNV::streamCount

  • VUID-VkIndirectCommandsLayoutTokenNV-offset-02952
    offset must be less than or equal to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::maxIndirectCommandsTokenOffset

  • VUID-VkIndirectCommandsLayoutTokenNV-offset-06888
    offset must be aligned to the scalar alignment of tokenType or minIndirectCommandsBufferOffsetAlignment, whichever is lower

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02976
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV, vertexBindingUnit must stay within device supported limits for the appropriate commands

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02977
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, pushconstantPipelineLayout must be valid

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02978
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, pushconstantOffset must be a multiple of 4

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02979
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, pushconstantSize must be a multiple of 4

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02980
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, pushconstantOffset must be less than VkPhysicalDeviceLimits::maxPushConstantsSize

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02981
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, pushconstantSize must be less than or equal to VkPhysicalDeviceLimits::maxPushConstantsSize minus pushconstantOffset

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02982
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, for each byte in the range specified by pushconstantOffset and pushconstantSize and for each shader stage in pushconstantShaderStageFlags, there must be a push constant range in pushconstantPipelineLayout that includes that byte and that stage

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02983
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, for each byte in the range specified by pushconstantOffset and pushconstantSize and for each push constant range that overlaps that byte, pushconstantShaderStageFlags must include all stages in that push constant range’s VkPushConstantRange::stageFlags

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-02984
    If tokenType is VK_INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV, indirectStateFlags must not be 0

Valid Usage (Implicit)
  • VUID-VkIndirectCommandsLayoutTokenNV-sType-sType
    sType must be VK_STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_TOKEN_NV

  • VUID-VkIndirectCommandsLayoutTokenNV-pNext-pNext
    pNext must be NULL

  • VUID-VkIndirectCommandsLayoutTokenNV-tokenType-parameter
    tokenType must be a valid VkIndirectCommandsTokenTypeNV value

  • VUID-VkIndirectCommandsLayoutTokenNV-pushconstantPipelineLayout-parameter
    If pushconstantPipelineLayout is not VK_NULL_HANDLE, pushconstantPipelineLayout must be a valid VkPipelineLayout handle

  • VUID-VkIndirectCommandsLayoutTokenNV-pushconstantShaderStageFlags-parameter
    pushconstantShaderStageFlags must be a valid combination of VkShaderStageFlagBits values

  • VUID-VkIndirectCommandsLayoutTokenNV-indirectStateFlags-parameter
    indirectStateFlags must be a valid combination of VkIndirectStateFlagBitsNV values

  • VUID-VkIndirectCommandsLayoutTokenNV-pIndexTypes-parameter
    If indexTypeCount is not 0, pIndexTypes must be a valid pointer to an array of indexTypeCount valid VkIndexType values

  • VUID-VkIndirectCommandsLayoutTokenNV-pIndexTypeValues-parameter
    If indexTypeCount is not 0, pIndexTypeValues must be a valid pointer to an array of indexTypeCount uint32_t values

The following code provides detailed information on how an individual sequence is processed. For valid usage, all restrictions from the regular commands apply.

void cmdProcessSequence(cmd, pipeline, indirectCommandsLayout, pIndirectCommandsStreams, s)
{
  for (uint32_t t = 0; t < indirectCommandsLayout.tokenCount; t++){
    token = indirectCommandsLayout.pTokens[t];

    uint32_t stride   = indirectCommandsLayout.pStreamStrides[token.stream];
    stream            = pIndirectCommandsStreams[token.stream];
    uint32_t offset   = stream.offset + stride * s + token.offset;
    const void* input = stream.buffer.pointer( offset )

    switch(input.type){
    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV:
      VkBindShaderGroupIndirectCommandNV* bind = input;

      vkCmdBindPipelineShaderGroupNV(cmd, indirectCommandsLayout.pipelineBindPoint,
        pipeline, bind->groupIndex);
    break;

    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV:
      VkSetStateFlagsIndirectCommandNV* state = input;

      if (token.indirectStateFlags & VK_INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV){
        if (state.data & (1 << 0)){
          set VK_FRONT_FACE_CLOCKWISE;
        } else {
          set VK_FRONT_FACE_COUNTER_CLOCKWISE;
        }
      }
    break;

    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV:
      uint32_t* data = input;

      vkCmdPushConstants(cmd,
        token.pushconstantPipelineLayout
        token.pushconstantStageFlags,
        token.pushconstantOffset,
        token.pushconstantSize, data);
    break;

    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV:
      VkBindIndexBufferIndirectCommandNV* data = input;

      // the indexType may optionally be remapped
      // from a custom uint32_t value, via
      // VkIndirectCommandsLayoutTokenNV::pIndexTypeValues

      vkCmdBindIndexBuffer(cmd,
        deriveBuffer(data->bufferAddress),
        deriveOffset(data->bufferAddress),
        data->indexType);
    break;

    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV:
      VkBindVertexBufferIndirectCommandNV* data = input;

      // if token.vertexDynamicStride is VK_TRUE
      // then the stride for this binding is set
      // using data->stride as well

      vkCmdBindVertexBuffers(cmd,
        token.vertexBindingUnit, 1,
        &deriveBuffer(data->bufferAddress),
        &deriveOffset(data->bufferAddress));
    break;

    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV:
      vkCmdDrawIndexedIndirect(cmd,
        stream.buffer, offset, 1, 0);
    break;

    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV:
      vkCmdDrawIndirect(cmd,
        stream.buffer,
        offset, 1, 0);
    break;

    // only available if VK_NV_mesh_shader is supported
    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV:
      vkCmdDrawMeshTasksIndirectNV(cmd,
        stream.buffer, offset, 1, 0);
    break;

    // only available if VK_EXT_mesh_shader is supported
    case VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_MESH_TASKS_NV:
      vkCmdDrawMeshTasksIndirectEXT(cmd,
        stream.buffer, offset, 1, 0);
    break;


    }
  }
}

32.2. Indirect Commands Generation And Execution

The generation of commands on the device requires a preprocess buffer. To retrieve the memory size and alignment requirements of a particular execution state call:

// Provided by VK_NV_device_generated_commands
void vkGetGeneratedCommandsMemoryRequirementsNV(
    VkDevice                                    device,
    const VkGeneratedCommandsMemoryRequirementsInfoNV* pInfo,
    VkMemoryRequirements2*                      pMemoryRequirements);
  • device is the logical device that owns the buffer.

  • pInfo is a pointer to a VkGeneratedCommandsMemoryRequirementsInfoNV structure containing parameters required for the memory requirements query.

  • pMemoryRequirements is a pointer to a VkMemoryRequirements2 structure in which the memory requirements of the buffer object are returned.

Valid Usage
Valid Usage (Implicit)
  • VUID-vkGetGeneratedCommandsMemoryRequirementsNV-device-parameter
    device must be a valid VkDevice handle

  • VUID-vkGetGeneratedCommandsMemoryRequirementsNV-pInfo-parameter
    pInfo must be a valid pointer to a valid VkGeneratedCommandsMemoryRequirementsInfoNV structure

  • VUID-vkGetGeneratedCommandsMemoryRequirementsNV-pMemoryRequirements-parameter
    pMemoryRequirements must be a valid pointer to a VkMemoryRequirements2 structure

// Provided by VK_NV_device_generated_commands
typedef struct VkGeneratedCommandsMemoryRequirementsInfoNV {
    VkStructureType               sType;
    const void*                   pNext;
    VkPipelineBindPoint           pipelineBindPoint;
    VkPipeline                    pipeline;
    VkIndirectCommandsLayoutNV    indirectCommandsLayout;
    uint32_t                      maxSequencesCount;
} VkGeneratedCommandsMemoryRequirementsInfoNV;
  • sType is a VkStructureType value identifying this structure.

  • pNext is NULL or a pointer to a structure extending this structure.

  • pipelineBindPoint is the VkPipelineBindPoint of the pipeline that this buffer memory is intended to be used with during the execution.

  • pipeline is the VkPipeline that this buffer memory is intended to be used with during the execution.

  • indirectCommandsLayout is the VkIndirectCommandsLayoutNV that this buffer memory is intended to be used with.

  • maxSequencesCount is the maximum number of sequences that this buffer memory in combination with the other state provided can be used with.

Valid Usage
  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-maxSequencesCount-02907
    maxSequencesCount must be less or equal to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::maxIndirectSequenceCount

  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-pipelineBindPoint-09075
    If pipelineBindPoint is of type VK_PIPELINE_BIND_POINT_GRAPHICS, then pipeline must be a valid VkPipeline handle

Valid Usage (Implicit)
  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-sType-sType
    sType must be VK_STRUCTURE_TYPE_GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_NV

  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-pNext-pNext
    pNext must be NULL

  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-pipelineBindPoint-parameter
    pipelineBindPoint must be a valid VkPipelineBindPoint value

  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-pipeline-parameter
    If pipeline is not VK_NULL_HANDLE, pipeline must be a valid VkPipeline handle

  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-indirectCommandsLayout-parameter
    indirectCommandsLayout must be a valid VkIndirectCommandsLayoutNV handle

  • VUID-VkGeneratedCommandsMemoryRequirementsInfoNV-commonparent
    Both of indirectCommandsLayout, and pipeline that are valid handles of non-ignored parameters must have been created, allocated, or retrieved from the same VkDevice

The actual generation of commands as well as their execution on the device is handled as single action with:

// Provided by VK_NV_device_generated_commands
void vkCmdExecuteGeneratedCommandsNV(
    VkCommandBuffer                             commandBuffer,
    VkBool32                                    isPreprocessed,
    const VkGeneratedCommandsInfoNV*            pGeneratedCommandsInfo);
  • commandBuffer is the command buffer into which the command is recorded.

  • isPreprocessed represents whether the input data has already been preprocessed on the device. If it is VK_FALSE this command will implicitly trigger the preprocessing step, otherwise not.

  • pGeneratedCommandsInfo is a pointer to a VkGeneratedCommandsInfoNV structure containing parameters affecting the generation of commands.

If the VK_INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV flag was used to create the VkGeneratedCommandsInfoNV::indirectCommandsLayout then the order of execution of individual draws through this command may execute in any order, and may not necessarily be in the same order as specified in VkGeneratedCommandsInfoNV::pStreams.

Valid Usage
  • VUID-vkCmdExecuteGeneratedCommandsNV-magFilter-04553
    If a VkSampler created with magFilter or minFilter equal to VK_FILTER_LINEAR and compareEnable equal to VK_FALSE is used to sample a VkImageView as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-mipmapMode-04770
    If a VkSampler created with mipmapMode equal to VK_SAMPLER_MIPMAP_MODE_LINEAR and compareEnable equal to VK_FALSE is used to sample a VkImageView as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06479
    If a VkImageView is sampled with depth comparison, the image view’s format features must contain VK_FORMAT_FEATURE_2_SAMPLED_IMAGE_DEPTH_COMPARISON_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02691
    If a VkImageView is accessed using atomic operations as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_STORAGE_IMAGE_ATOMIC_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07888
    If a VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER descriptor is accessed using atomic operations as a result of this command, then the storage texel buffer’s format features must contain VK_FORMAT_FEATURE_STORAGE_TEXEL_BUFFER_ATOMIC_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02692
    If a VkImageView is sampled with VK_FILTER_CUBIC_EXT as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_CUBIC_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02693
    If the VK_EXT_filter_cubic extension is not enabled and any VkImageView is sampled with VK_FILTER_CUBIC_EXT as a result of this command, it must not have a VkImageViewType of VK_IMAGE_VIEW_TYPE_3D, VK_IMAGE_VIEW_TYPE_CUBE, or VK_IMAGE_VIEW_TYPE_CUBE_ARRAY

  • VUID-vkCmdExecuteGeneratedCommandsNV-filterCubic-02694
    Any VkImageView being sampled with VK_FILTER_CUBIC_EXT as a result of this command must have a VkImageViewType and format that supports cubic filtering, as specified by VkFilterCubicImageViewImageFormatPropertiesEXT::filterCubic returned by vkGetPhysicalDeviceImageFormatProperties2

  • VUID-vkCmdExecuteGeneratedCommandsNV-filterCubicMinmax-02695
    Any VkImageView being sampled with VK_FILTER_CUBIC_EXT with a reduction mode of either VK_SAMPLER_REDUCTION_MODE_MIN or VK_SAMPLER_REDUCTION_MODE_MAX as a result of this command must have a VkImageViewType and format that supports cubic filtering together with minmax filtering, as specified by VkFilterCubicImageViewImageFormatPropertiesEXT::filterCubicMinmax returned by vkGetPhysicalDeviceImageFormatProperties2

  • VUID-vkCmdExecuteGeneratedCommandsNV-flags-02696
    Any VkImage created with a VkImageCreateInfo::flags containing VK_IMAGE_CREATE_CORNER_SAMPLED_BIT_NV sampled as a result of this command must only be sampled using a VkSamplerAddressMode of VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpTypeImage-07027
    For any VkImageView being written as a storage image where the image format field of the OpTypeImage is Unknown, the view’s format features must contain VK_FORMAT_FEATURE_2_STORAGE_WRITE_WITHOUT_FORMAT_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpTypeImage-07028
    For any VkImageView being read as a storage image where the image format field of the OpTypeImage is Unknown, the view’s format features must contain VK_FORMAT_FEATURE_2_STORAGE_READ_WITHOUT_FORMAT_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpTypeImage-07029
    For any VkBufferView being written as a storage texel buffer where the image format field of the OpTypeImage is Unknown, the view’s buffer features must contain VK_FORMAT_FEATURE_2_STORAGE_WRITE_WITHOUT_FORMAT_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpTypeImage-07030
    Any VkBufferView being read as a storage texel buffer where the image format field of the OpTypeImage is Unknown then the view’s buffer features must contain VK_FORMAT_FEATURE_2_STORAGE_READ_WITHOUT_FORMAT_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02697
    For each set n that is statically used by a bound shader, a descriptor set must have been bound to n at the same pipeline bind point, with a VkPipelineLayout that is compatible for set n, with the VkPipelineLayout used to create the current VkPipeline, as described in Pipeline Layout Compatibility

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02698
    For each push constant that is statically used by a bound shader, a push constant value must have been set for the same pipeline bind point, with a VkPipelineLayout that is compatible for push constants, with the VkPipelineLayout used to create the current VkPipeline, as described in Pipeline Layout Compatibility

  • VUID-vkCmdExecuteGeneratedCommandsNV-maintenance4-06425
    If the maintenance4 feature is not enabled, then for each push constant that is statically used by a bound shader, a push constant value must have been set for the same pipeline bind point, with a VkPipelineLayout that is compatible for push constants, with the VkPipelineLayout used to create the current VkPipeline, as described in Pipeline Layout Compatibility

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-08114
    Descriptors in each bound descriptor set, specified via vkCmdBindDescriptorSets, must be valid if they are statically used by the VkPipeline bound to the pipeline bind point used by this command and the bound VkPipeline was not created with VK_PIPELINE_CREATE_DESCRIPTOR_BUFFER_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-08115
    If the descriptors used by the VkPipeline bound to the pipeline bind point were specified via vkCmdBindDescriptorSets, the bound VkPipeline must have been created without VK_PIPELINE_CREATE_DESCRIPTOR_BUFFER_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-08116
    Descriptors in bound descriptor buffers, specified via vkCmdSetDescriptorBufferOffsetsEXT, must be valid if they are dynamically used by the VkPipeline bound to the pipeline bind point used by this command and the bound VkPipeline was created with VK_PIPELINE_CREATE_DESCRIPTOR_BUFFER_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-08117
    If the descriptors used by the VkPipeline bound to the pipeline bind point were specified via vkCmdSetDescriptorBufferOffsetsEXT, the bound VkPipeline must have been created with VK_PIPELINE_CREATE_DESCRIPTOR_BUFFER_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-08119
    If a descriptor is dynamically used with a VkPipeline created with VK_PIPELINE_CREATE_DESCRIPTOR_BUFFER_BIT_EXT, the descriptor memory must be resident

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02700
    A valid pipeline must be bound to the pipeline bind point used by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02859
    There must not have been any calls to dynamic state setting commands for any state not specified as dynamic in the VkPipeline object bound to the pipeline bind point used by this command, since that pipeline was bound

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02702
    If the VkPipeline object bound to the pipeline bind point used by this command accesses a VkSampler object that uses unnormalized coordinates, that sampler must not be used to sample from any VkImage with a VkImageView of the type VK_IMAGE_VIEW_TYPE_3D, VK_IMAGE_VIEW_TYPE_CUBE, VK_IMAGE_VIEW_TYPE_1D_ARRAY, VK_IMAGE_VIEW_TYPE_2D_ARRAY or VK_IMAGE_VIEW_TYPE_CUBE_ARRAY, in any shader stage

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02703
    If the VkPipeline object bound to the pipeline bind point used by this command accesses a VkSampler object that uses unnormalized coordinates, that sampler must not be used with any of the SPIR-V OpImageSample* or OpImageSparseSample* instructions with ImplicitLod, Dref or Proj in their name, in any shader stage

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02704
    If the VkPipeline object bound to the pipeline bind point used by this command accesses a VkSampler object that uses unnormalized coordinates, that sampler must not be used with any of the SPIR-V OpImageSample* or OpImageSparseSample* instructions that includes a LOD bias or any offset values, in any shader stage

  • VUID-vkCmdExecuteGeneratedCommandsNV-uniformBuffers-06935
    If any stage of the VkPipeline object bound to the pipeline bind point used by this command accesses a uniform buffer, and that stage was created without enabling either VK_PIPELINE_ROBUSTNESS_BUFFER_BEHAVIOR_ROBUST_BUFFER_ACCESS_EXT or VK_PIPELINE_ROBUSTNESS_BUFFER_BEHAVIOR_ROBUST_BUFFER_ACCESS_2_EXT for uniformBuffers, and the robustBufferAccess feature is not enabled, that stage must not access values outside of the range of the buffer as specified in the descriptor set bound to the same pipeline bind point

  • VUID-vkCmdExecuteGeneratedCommandsNV-storageBuffers-06936
    If any stage of the VkPipeline object bound to the pipeline bind point used by this command accesses a storage buffer, and that stage was created without enabling either VK_PIPELINE_ROBUSTNESS_BUFFER_BEHAVIOR_ROBUST_BUFFER_ACCESS_EXT or VK_PIPELINE_ROBUSTNESS_BUFFER_BEHAVIOR_ROBUST_BUFFER_ACCESS_2_EXT for storageBuffers, and the robustBufferAccess feature is not enabled, that stage must not access values outside of the range of the buffer as specified in the descriptor set bound to the same pipeline bind point

  • VUID-vkCmdExecuteGeneratedCommandsNV-commandBuffer-02707
    If commandBuffer is an unprotected command buffer and protectedNoFault is not supported, any resource accessed by bound shaders must not be a protected resource

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06550
    If a bound shader accesses a VkSampler or VkImageView object that enables sampler Y′CBCR conversion, that object must only be used with OpImageSample* or OpImageSparseSample* instructions

  • VUID-vkCmdExecuteGeneratedCommandsNV-ConstOffset-06551
    If a bound shader accesses a VkSampler or VkImageView object that enables sampler Y′CBCR conversion, that object must not use the ConstOffset and Offset operands

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewType-07752
    If a VkImageView is accessed as a result of this command, then the image view’s viewType must match the Dim operand of the OpTypeImage as described in Instruction/Sampler/Image View Validation

  • VUID-vkCmdExecuteGeneratedCommandsNV-format-07753
    If a VkImageView is accessed as a result of this command, then the numeric type of the image view’s format and the Sampled Type operand of the OpTypeImage must match

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageWrite-08795
    If a VkImageView is accessed using OpImageWrite as a result of this command, then the Type of the Texel operand of that instruction must have at least as many components as the image view’s format

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageWrite-04469
    If a VkBufferView is accessed using OpImageWrite as a result of this command, then the Type of the Texel operand of that instruction must have at least as many components as the buffer view’s format

  • VUID-vkCmdExecuteGeneratedCommandsNV-SampledType-04470
    If a VkImageView with a VkFormat that has a 64-bit component width is accessed as a result of this command, the SampledType of the OpTypeImage operand of that instruction must have a Width of 64

  • VUID-vkCmdExecuteGeneratedCommandsNV-SampledType-04471
    If a VkImageView with a VkFormat that has a component width less than 64-bit is accessed as a result of this command, the SampledType of the OpTypeImage operand of that instruction must have a Width of 32

  • VUID-vkCmdExecuteGeneratedCommandsNV-SampledType-04472
    If a VkBufferView with a VkFormat that has a 64-bit component width is accessed as a result of this command, the SampledType of the OpTypeImage operand of that instruction must have a Width of 64

  • VUID-vkCmdExecuteGeneratedCommandsNV-SampledType-04473
    If a VkBufferView with a VkFormat that has a component width less than 64-bit is accessed as a result of this command, the SampledType of the OpTypeImage operand of that instruction must have a Width of 32

  • VUID-vkCmdExecuteGeneratedCommandsNV-sparseImageInt64Atomics-04474
    If the sparseImageInt64Atomics feature is not enabled, VkImage objects created with the VK_IMAGE_CREATE_SPARSE_RESIDENCY_BIT flag must not be accessed by atomic instructions through an OpTypeImage with a SampledType with a Width of 64 by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-sparseImageInt64Atomics-04475
    If the sparseImageInt64Atomics feature is not enabled, VkBuffer objects created with the VK_BUFFER_CREATE_SPARSE_RESIDENCY_BIT flag must not be accessed by atomic instructions through an OpTypeImage with a SampledType with a Width of 64 by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageWeightedSampleQCOM-06971
    If OpImageWeightedSampleQCOM is used to sample a VkImageView as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_2_WEIGHT_SAMPLED_IMAGE_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageWeightedSampleQCOM-06972
    If OpImageWeightedSampleQCOM uses a VkImageView as a sample weight image as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_2_WEIGHT_IMAGE_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageBoxFilterQCOM-06973
    If OpImageBoxFilterQCOM is used to sample a VkImageView as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_2_BOX_FILTER_SAMPLED_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageBlockMatchSSDQCOM-06974
    If OpImageBlockMatchSSDQCOM is used to read from an VkImageView as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_2_BLOCK_MATCHING_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageBlockMatchSADQCOM-06975
    If OpImageBlockMatchSADQCOM is used to read from an VkImageView as a result of this command, then the image view’s format features must contain VK_FORMAT_FEATURE_2_BLOCK_MATCHING_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageBlockMatchSADQCOM-06976
    If OpImageBlockMatchSADQCOM or OpImageBlockMatchSSDQCOM is used to read from a reference image as result of this command, then the specified reference coordinates must not fail integer texel coordinate validation

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageWeightedSampleQCOM-06977
    If OpImageWeightedSampleQCOM, OpImageBoxFilterQCOM, OpImageBlockMatchSSDQCOM, or OpImageBlockMatchSADQCOM uses a VkSampler as a result of this command, then the sampler must have been created with VK_SAMPLER_CREATE_IMAGE_PROCESSING_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpImageWeightedSampleQCOM-06978
    If any command other than OpImageWeightedSampleQCOM, OpImageBoxFilterQCOM, OpImageBlockMatchSSDQCOM, or OpImageBlockMatchSADQCOM uses a VkSampler as a result of this command, then the sampler must not have been created with VK_SAMPLER_CREATE_IMAGE_PROCESSING_BIT_QCOM

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07288
    Any shader invocation executed by this command must terminate

  • VUID-vkCmdExecuteGeneratedCommandsNV-renderPass-02684
    The current render pass must be compatible with the renderPass member of the VkGraphicsPipelineCreateInfo structure specified when creating the VkPipeline bound to VK_PIPELINE_BIND_POINT_GRAPHICS

  • VUID-vkCmdExecuteGeneratedCommandsNV-subpass-02685
    The subpass index of the current render pass must be equal to the subpass member of the VkGraphicsPipelineCreateInfo structure specified when creating the VkPipeline bound to VK_PIPELINE_BIND_POINT_GRAPHICS

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07748
    If any shader statically accesses an input attachment, a valid descriptor must be bound to the pipeline via a descriptor set

  • VUID-vkCmdExecuteGeneratedCommandsNV-OpTypeImage-07468
    If any shader executed by this pipeline accesses an OpTypeImage variable with a Dim operand of SubpassData, it must be decorated with an InputAttachmentIndex that corresponds to a valid input attachment in the current subpass

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07469
    Input attachment views accessed in a subpass must be created with the same VkFormat as the corresponding subpass definition, and be created with a VkImageView that is compatible with the attachment referenced by the subpass' pInputAttachments[InputAttachmentIndex] in the currently bound VkFramebuffer as specified by Fragment Input Attachment Compatibility

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06537
    Memory backing image subresources used as attachments in the current render pass must not be written in any way other than as an attachment by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09000
    If a color attachment is written by any prior command in this subpass or by the load, store, or resolve operations for this subpass, it is not in the VK_IMAGE_LAYOUT_ATTACHMENT_FEEDBACK_LOOP_OPTIMAL_EXT image layout, and the VK_PIPELINE_CREATE_COLOR_ATTACHMENT_FEEDBACK_LOOP_BIT_EXT is set on the currently bound pipeline it must not be accessed in any way other than as an attachment by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09001
    If a depth attachment is written by any prior command in this subpass or by the load, store, or resolve operations for this subpass, it is not in the VK_IMAGE_LAYOUT_ATTACHMENT_FEEDBACK_LOOP_OPTIMAL_EXT image layout, and the VK_PIPELINE_CREATE_DEPTH_STENCIL_ATTACHMENT_FEEDBACK_LOOP_BIT_EXT is set on the currently bound pipeline it must not be accessed in any way other than as an attachment by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09002
    If a stencil attachment is written by any prior command in this subpass or by the load, store, or resolve operations for this subpass, it is not in the VK_IMAGE_LAYOUT_ATTACHMENT_FEEDBACK_LOOP_OPTIMAL_EXT image layout, and the VK_PIPELINE_CREATE_DEPTH_STENCIL_ATTACHMENT_FEEDBACK_LOOP_BIT_EXT is set on the currently bound pipeline it must not be accessed in any way other than as an attachment by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09003
    If an attachment is written by any prior command in this subpass or by the load, store, or resolve operations for this subpass, it must not be accessed in any way other than as an attachment, storage image, or sampled image by this command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06539
    If any previously recorded command in the current subpass accessed an image subresource used as an attachment in this subpass in any way other than as an attachment, this command must not write to that image subresource as an attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06886
    If the current render pass instance uses a depth/stencil attachment with a read-only layout for the depth aspect, depth writes must be disabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06887
    If the current render pass instance uses a depth/stencil attachment with a read-only layout for the stencil aspect, both front and back writeMask are not zero, and stencil test is enabled, all stencil ops must be VK_STENCIL_OP_KEEP

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07831
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT dynamic state enabled then vkCmdSetViewport must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07832
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SCISSOR dynamic state enabled then vkCmdSetScissor must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07833
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_WIDTH dynamic state enabled then vkCmdSetLineWidth must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07834
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_BIAS dynamic state enabled then vkCmdSetDepthBias must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07835
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_BLEND_CONSTANTS dynamic state enabled then vkCmdSetBlendConstants must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07836
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_BOUNDS dynamic state enabled then vkCmdSetDepthBounds must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07837
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_STENCIL_COMPARE_MASK dynamic state enabled then vkCmdSetStencilCompareMask must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07838
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_STENCIL_WRITE_MASK dynamic state enabled then vkCmdSetStencilWriteMask must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07839
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_STENCIL_REFERENCE dynamic state enabled then vkCmdSetStencilReference must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-maxMultiviewInstanceIndex-02688
    If the draw is recorded in a render pass instance with multiview enabled, the maximum instance index must be less than or equal to VkPhysicalDeviceMultiviewProperties::maxMultiviewInstanceIndex

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-02689
    If the bound graphics pipeline was created with VkPipelineSampleLocationsStateCreateInfoEXT::sampleLocationsEnable set to VK_TRUE and the current subpass has a depth/stencil attachment, then that attachment must have been created with the VK_IMAGE_CREATE_SAMPLE_LOCATIONS_COMPATIBLE_DEPTH_BIT_EXT bit set

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-06666
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT dynamic state enabled then vkCmdSetSampleLocationsEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsPerPixel-07934
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state enabled, then the sampleLocationsPerPixel member of pSampleLocationsInfo in the last call to vkCmdSetSampleLocationsEXT must equal the rasterizationSamples member of the VkPipelineMultisampleStateCreateInfo structure the bound graphics pipeline has been created with

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07840
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_CULL_MODE dynamic state enabled then vkCmdSetCullMode must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07841
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_FRONT_FACE dynamic state enabled then vkCmdSetFrontFace must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07843
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_TEST_ENABLE dynamic state enabled then vkCmdSetDepthTestEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07844
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_WRITE_ENABLE dynamic state enabled then vkCmdSetDepthWriteEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07845
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_COMPARE_OP dynamic state enabled then vkCmdSetDepthCompareOp must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07846
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_BOUNDS_TEST_ENABLE dynamic state enabled then vkCmdSetDepthBoundsTestEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07847
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_STENCIL_TEST_ENABLE dynamic state enabled then vkCmdSetStencilTestEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07848
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_STENCIL_OP dynamic state enabled then vkCmdSetStencilOp must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-03417
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled, but not the VK_DYNAMIC_STATE_SCISSOR_WITH_COUNT dynamic state enabled, then vkCmdSetViewportWithCount must have been called in the current command buffer prior to this drawing command, and the viewportCount parameter of vkCmdSetViewportWithCount must match the VkPipelineViewportStateCreateInfo::scissorCount of the pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-scissorCount-03418
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SCISSOR_WITH_COUNT dynamic state enabled, but not the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled, then vkCmdSetScissorWithCount must have been called in the current command buffer prior to this drawing command, and the scissorCount parameter of vkCmdSetScissorWithCount must match the VkPipelineViewportStateCreateInfo::viewportCount of the pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-03419
    If the bound graphics pipeline state was created with both the VK_DYNAMIC_STATE_SCISSOR_WITH_COUNT and VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic states enabled then both vkCmdSetViewportWithCount and vkCmdSetScissorWithCount must have been called in the current command buffer prior to this drawing command, and the viewportCount parameter of vkCmdSetViewportWithCount must match the scissorCount parameter of vkCmdSetScissorWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-04137
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled, but not the VK_DYNAMIC_STATE_VIEWPORT_W_SCALING_NV dynamic state enabled, then the bound graphics pipeline must have been created with VkPipelineViewportWScalingStateCreateInfoNV::viewportCount greater or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-04138
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT and VK_DYNAMIC_STATE_VIEWPORT_W_SCALING_NV dynamic states enabled then the viewportCount parameter in the last call to vkCmdSetViewportWScalingNV must be greater than or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-04139
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled, but not the VK_DYNAMIC_STATE_VIEWPORT_SHADING_RATE_PALETTE_NV dynamic state enabled, then the bound graphics pipeline must have been created with VkPipelineViewportShadingRateImageStateCreateInfoNV::viewportCount greater or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-04140
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT and VK_DYNAMIC_STATE_VIEWPORT_SHADING_RATE_PALETTE_NV dynamic states enabled then the viewportCount parameter in the last call to vkCmdSetViewportShadingRatePaletteNV must be greater than or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-VkPipelineVieportCreateInfo-04141
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled and a VkPipelineViewportSwizzleStateCreateInfoNV structure chained from VkPipelineViewportStateCreateInfo, then the bound graphics pipeline must have been created with VkPipelineViewportSwizzleStateCreateInfoNV::viewportCount greater or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-VkPipelineVieportCreateInfo-04142
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled and a VkPipelineViewportExclusiveScissorStateCreateInfoNV structure chained from VkPipelineViewportStateCreateInfo, then the bound graphics pipeline must have been created with VkPipelineViewportExclusiveScissorStateCreateInfoNV::exclusiveScissorCount greater or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07878
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_EXCLUSIVE_SCISSOR_ENABLE_NV dynamic state enabled then vkCmdSetExclusiveScissorEnableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07879
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_EXCLUSIVE_SCISSOR_NV dynamic state enabled then vkCmdSetExclusiveScissorNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04876
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_RASTERIZER_DISCARD_ENABLE dynamic state enabled then vkCmdSetRasterizerDiscardEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04877
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_BIAS_ENABLE dynamic state enabled then vkCmdSetDepthBiasEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-logicOp-04878
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LOGIC_OP_EXT dynamic state enabled then vkCmdSetLogicOpEXT must have been called in the current command buffer prior to this drawing command and the logicOp must be a valid VkLogicOp value

  • VUID-vkCmdExecuteGeneratedCommandsNV-primitiveFragmentShadingRateWithMultipleViewports-04552
    If the primitiveFragmentShadingRateWithMultipleViewports limit is not supported, the bound graphics pipeline was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled, and any of the shader stages of the bound graphics pipeline write to the PrimitiveShadingRateKHR built-in, then vkCmdSetViewportWithCount must have been called in the current command buffer prior to this drawing command, and the viewportCount parameter of vkCmdSetViewportWithCount must be 1

  • VUID-vkCmdExecuteGeneratedCommandsNV-blendEnable-04727
    If rasterization is not disabled in the bound graphics pipeline, then for each color attachment in the subpass, if the corresponding image view’s format features do not contain VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BLEND_BIT, then the blendEnable member of the corresponding element of the pAttachments member of pColorBlendState must be VK_FALSE

  • VUID-vkCmdExecuteGeneratedCommandsNV-multisampledRenderToSingleSampled-07284
    If rasterization is not disabled in the bound graphics pipeline, and none of the VK_AMD_mixed_attachment_samples extension, the VK_NV_framebuffer_mixed_samples extension, or the multisampledRenderToSingleSampled feature is enabled, then rasterizationSamples for the currently bound graphics pipeline must be the same as the current subpass color and/or depth/stencil attachments

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06172
    If the current render pass instance was begun with vkCmdBeginRendering, the imageView member of pDepthAttachment is not VK_NULL_HANDLE, and the layout member of pDepthAttachment is VK_IMAGE_LAYOUT_DEPTH_STENCIL_READ_ONLY_OPTIMAL, this command must not write any values to the depth attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06173
    If the current render pass instance was begun with vkCmdBeginRendering, the imageView member of pStencilAttachment is not VK_NULL_HANDLE, and the layout member of pStencilAttachment is VK_IMAGE_LAYOUT_DEPTH_STENCIL_READ_ONLY_OPTIMAL, this command must not write any values to the stencil attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06174
    If the current render pass instance was begun with vkCmdBeginRendering, the imageView member of pDepthAttachment is not VK_NULL_HANDLE, and the layout member of pDepthAttachment is VK_IMAGE_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_OPTIMAL, this command must not write any values to the depth attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06175
    If the current render pass instance was begun with vkCmdBeginRendering, the imageView member of pStencilAttachment is not VK_NULL_HANDLE, and the layout member of pStencilAttachment is VK_IMAGE_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_OPTIMAL, this command must not write any values to the stencil attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06176
    If the current render pass instance was begun with vkCmdBeginRendering, the imageView member of pDepthAttachment is not VK_NULL_HANDLE, and the layout member of pDepthAttachment is VK_IMAGE_LAYOUT_DEPTH_READ_ONLY_OPTIMAL, this command must not write any values to the depth attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06177
    If the current render pass instance was begun with vkCmdBeginRendering, the imageView member of pStencilAttachment is not VK_NULL_HANDLE, and the layout member of pStencilAttachment is VK_IMAGE_LAYOUT_STENCIL_READ_ONLY_OPTIMAL, this command must not write any values to the stencil attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewMask-06178
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound graphics pipeline must have been created with a VkPipelineRenderingCreateInfo::viewMask equal to VkRenderingInfo::viewMask

  • VUID-vkCmdExecuteGeneratedCommandsNV-colorAttachmentCount-06179
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound graphics pipeline must have been created with a VkPipelineRenderingCreateInfo::colorAttachmentCount equal to VkRenderingInfo::colorAttachmentCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-colorAttachmentCount-06180
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingInfo::colorAttachmentCount greater than 0, then each element of the VkRenderingInfo::pColorAttachments array with a imageView not equal to VK_NULL_HANDLE must have been created with a VkFormat equal to the corresponding element of VkPipelineRenderingCreateInfo::pColorAttachmentFormats used to create the currently bound graphics pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-colorAttachmentCount-07616
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingInfo::colorAttachmentCount greater than 0, then each element of the VkRenderingInfo::pColorAttachments array with a imageView equal to VK_NULL_HANDLE must have the corresponding element of VkPipelineRenderingCreateInfo::pColorAttachmentFormats used to create the currently bound pipeline equal to VK_FORMAT_UNDEFINED

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07749
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXT dynamic state enabled then vkCmdSetColorWriteEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-attachmentCount-07750
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXT dynamic state enabled then the attachmentCount parameter of vkCmdSetColorWriteEnableEXT must be greater than or equal to the VkPipelineColorBlendStateCreateInfo::attachmentCount of the currently bound graphics pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07751
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DISCARD_RECTANGLE_EXT dynamic state enabled then vkCmdSetDiscardRectangleEXT must have been called in the current command buffer prior to this drawing command for each discard rectangle in VkPipelineDiscardRectangleStateCreateInfoEXT::discardRectangleCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07880
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DISCARD_RECTANGLE_ENABLE_EXT dynamic state enabled then vkCmdSetDiscardRectangleEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07881
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DISCARD_RECTANGLE_MODE_EXT dynamic state enabled then vkCmdSetDiscardRectangleModeEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-pDepthAttachment-06181
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingInfo::pDepthAttachment->imageView was not VK_NULL_HANDLE, the value of VkPipelineRenderingCreateInfo::depthAttachmentFormat used to create the currently bound graphics pipeline must be equal to the VkFormat used to create VkRenderingInfo::pDepthAttachment->imageView

  • VUID-vkCmdExecuteGeneratedCommandsNV-pDepthAttachment-07617
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingInfo::pDepthAttachment->imageView was VK_NULL_HANDLE, the value of VkPipelineRenderingCreateInfo::depthAttachmentFormat used to create the currently bound graphics pipeline must be equal to VK_FORMAT_UNDEFINED

  • VUID-vkCmdExecuteGeneratedCommandsNV-pStencilAttachment-06182
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingInfo::pStencilAttachment->imageView was not VK_NULL_HANDLE, the value of VkPipelineRenderingCreateInfo::stencilAttachmentFormat used to create the currently bound graphics pipeline must be equal to the VkFormat used to create VkRenderingInfo::pStencilAttachment->imageView

  • VUID-vkCmdExecuteGeneratedCommandsNV-pStencilAttachment-07618
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingInfo::pStencilAttachment->imageView was VK_NULL_HANDLE, the value of VkPipelineRenderingCreateInfo::stencilAttachmentFormat used to create the currently bound graphics pipeline must be equal to VK_FORMAT_UNDEFINED

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06183
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingFragmentShadingRateAttachmentInfoKHR::imageView was not VK_NULL_HANDLE, the currently bound graphics pipeline must have been created with VK_PIPELINE_CREATE_RENDERING_FRAGMENT_SHADING_RATE_ATTACHMENT_BIT_KHR

  • VUID-vkCmdExecuteGeneratedCommandsNV-imageView-06184
    If the current render pass instance was begun with vkCmdBeginRendering and VkRenderingFragmentDensityMapAttachmentInfoEXT::imageView was not VK_NULL_HANDLE, the currently bound graphics pipeline must have been created with VK_PIPELINE_CREATE_RENDERING_FRAGMENT_DENSITY_MAP_ATTACHMENT_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-colorAttachmentCount-06185
    If the currently bound pipeline was created with a VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV structure, and the current render pass instance was begun with vkCmdBeginRendering with a VkRenderingInfo::colorAttachmentCount parameter greater than 0, then each element of the VkRenderingInfo::pColorAttachments array with a imageView not equal to VK_NULL_HANDLE must have been created with a sample count equal to the corresponding element of the pColorAttachmentSamples member of VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV used to create the currently bound graphics pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-pDepthAttachment-06186
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound pipeline was created with a VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV structure, and VkRenderingInfo::pDepthAttachment->imageView was not VK_NULL_HANDLE, the value of the depthStencilAttachmentSamples member of VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV used to create the currently bound graphics pipeline must be equal to the sample count used to create VkRenderingInfo::pDepthAttachment->imageView

  • VUID-vkCmdExecuteGeneratedCommandsNV-pStencilAttachment-06187
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound pipeline was created with a VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV structure, and VkRenderingInfo::pStencilAttachment->imageView was not VK_NULL_HANDLE, the value of the depthStencilAttachmentSamples member of VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV used to create the currently bound graphics pipeline must be equal to the sample count used to create VkRenderingInfo::pStencilAttachment->imageView

  • VUID-vkCmdExecuteGeneratedCommandsNV-multisampledRenderToSingleSampled-07285
    If the currently bound pipeline was created without a VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV structure, and the multisampledRenderToSingleSampled feature is not enabled, and the current render pass instance was begun with vkCmdBeginRendering with a VkRenderingInfo::colorAttachmentCount parameter greater than 0, then each element of the VkRenderingInfo::pColorAttachments array with a imageView not equal to VK_NULL_HANDLE must have been created with a sample count equal to the value of rasterizationSamples for the currently bound graphics pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-multisampledRenderToSingleSampled-07286
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound pipeline was created without a VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV structure, and the multisampledRenderToSingleSampled feature is not enabled, and VkRenderingInfo::pDepthAttachment->imageView was not VK_NULL_HANDLE, the value of rasterizationSamples for the currently bound graphics pipeline must be equal to the sample count used to create VkRenderingInfo::pDepthAttachment->imageView

  • VUID-vkCmdExecuteGeneratedCommandsNV-multisampledRenderToSingleSampled-07287
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound pipeline was created without a VkAttachmentSampleCountInfoAMD or VkAttachmentSampleCountInfoNV structure, and the multisampledRenderToSingleSampled feature is not enabled, and VkRenderingInfo::pStencilAttachment->imageView was not VK_NULL_HANDLE, the value of rasterizationSamples for the currently bound graphics pipeline must be equal to the sample count used to create VkRenderingInfo::pStencilAttachment->imageView

  • VUID-vkCmdExecuteGeneratedCommandsNV-pNext-07935
    If this command has been called inside a render pass instance started with vkCmdBeginRendering, and the pNext chain of VkRenderingInfo includes a VkMultisampledRenderToSingleSampledInfoEXT structure with multisampledRenderToSingleSampledEnable equal to VK_TRUE, then the value of rasterizationSamples for the currently bound graphics pipeline must be equal to VkMultisampledRenderToSingleSampledInfoEXT::rasterizationSamples

  • VUID-vkCmdExecuteGeneratedCommandsNV-renderPass-06198
    If the current render pass instance was begun with vkCmdBeginRendering, the currently bound pipeline must have been created with a VkGraphicsPipelineCreateInfo::renderPass equal to VK_NULL_HANDLE

  • VUID-vkCmdExecuteGeneratedCommandsNV-pColorAttachments-08963
    If the current render pass instance was begun with vkCmdBeginRendering, there is a graphics pipeline bound with a fragment shader that statically writes to a color attachment, the color write mask is not zero, color writes are enabled, and the corresponding element of the VkRenderingInfo::pColorAttachments->imageView was not VK_NULL_HANDLE, then the corresponding element of VkPipelineRenderingCreateInfo::pColorAttachmentFormats used to create the pipeline must not be VK_FORMAT_UNDEFINED

  • VUID-vkCmdExecuteGeneratedCommandsNV-pDepthAttachment-08964
    If the current render pass instance was begun with vkCmdBeginRendering, there is a graphics pipeline bound, depth test is enabled, depth write is enabled, and the VkRenderingInfo::pDepthAttachment->imageView was not VK_NULL_HANDLE, then the VkPipelineRenderingCreateInfo::depthAttachmentFormat used to create the pipeline must not be VK_FORMAT_UNDEFINED

  • VUID-vkCmdExecuteGeneratedCommandsNV-pStencilAttachment-08965
    If the current render pass instance was begun with vkCmdBeginRendering, there is a graphics pipeline bound, stencil test is enabled and the VkRenderingInfo::pStencilAttachment->imageView was not VK_NULL_HANDLE, then the VkPipelineRenderingCreateInfo::stencilAttachmentFormat used to create the pipeline must not be VK_FORMAT_UNDEFINED

  • VUID-vkCmdExecuteGeneratedCommandsNV-primitivesGeneratedQueryWithRasterizerDiscard-06708
    If the primitivesGeneratedQueryWithRasterizerDiscard feature is not enabled and the VK_QUERY_TYPE_PRIMITIVES_GENERATED_EXT query is active, rasterization discard must not be enabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-primitivesGeneratedQueryWithNonZeroStreams-06709
    If the primitivesGeneratedQueryWithNonZeroStreams feature is not enabled and the VK_QUERY_TYPE_PRIMITIVES_GENERATED_EXT query is active, the bound graphics pipeline must not have been created with a non-zero value in VkPipelineRasterizationStateStreamCreateInfoEXT::rasterizationStream

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07619
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_TESSELLATION_DOMAIN_ORIGIN_EXT dynamic state enabled then vkCmdSetTessellationDomainOriginEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07620
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_CLAMP_ENABLE_EXT dynamic state enabled then vkCmdSetDepthClampEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07621
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_POLYGON_MODE_EXT dynamic state enabled then vkCmdSetPolygonModeEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07622
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT dynamic state enabled then vkCmdSetRasterizationSamplesEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07623
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_MASK_EXT dynamic state enabled then vkCmdSetSampleMaskEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07624
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_ALPHA_TO_COVERAGE_ENABLE_EXT dynamic state enabled then vkCmdSetAlphaToCoverageEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-alphaToCoverageEnable-08919
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_ALPHA_TO_COVERAGE_ENABLE_EXT dynamic state enabled, and alphaToCoverageEnable was VK_TRUE in the last call to vkCmdSetAlphaToCoverageEnableEXT, then the Fragment Output Interface must contain a variable for the alpha Component word in Location 0 at Index 0

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07625
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_ALPHA_TO_ONE_ENABLE_EXT dynamic state enabled then vkCmdSetAlphaToOneEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07626
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LOGIC_OP_ENABLE_EXT dynamic state enabled then vkCmdSetLogicOpEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07627
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_ENABLE_EXT dynamic state enabled then vkCmdSetColorBlendEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07628
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_EQUATION_EXT dynamic state enabled then vkCmdSetColorBlendEquationEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07629
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_WRITE_MASK_EXT dynamic state enabled then vkCmdSetColorWriteMaskEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07630
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_RASTERIZATION_STREAM_EXT dynamic state enabled then vkCmdSetRasterizationStreamEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07631
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_CONSERVATIVE_RASTERIZATION_MODE_EXT dynamic state enabled then vkCmdSetConservativeRasterizationModeEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07632
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_EXTRA_PRIMITIVE_OVERESTIMATION_SIZE_EXT dynamic state enabled then vkCmdSetExtraPrimitiveOverestimationSizeEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07633
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_CLIP_ENABLE_EXT dynamic state enabled then vkCmdSetDepthClipEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07634
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT dynamic state enabled then vkCmdSetSampleLocationsEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07635
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_ADVANCED_EXT dynamic state enabled then vkCmdSetColorBlendAdvancedEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07636
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_PROVOKING_VERTEX_MODE_EXT dynamic state enabled then vkCmdSetProvokingVertexModeEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07637
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_RASTERIZATION_MODE_EXT dynamic state enabled then vkCmdSetLineRasterizationModeEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07638
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_STIPPLE_ENABLE_EXT dynamic state enabled then vkCmdSetLineStippleEnableEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07849
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_STIPPLE_EXT dynamic state enabled then vkCmdSetLineStippleEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07639
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_DEPTH_CLIP_NEGATIVE_ONE_TO_ONE_EXT dynamic state enabled then vkCmdSetDepthClipNegativeOneToOneEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07640
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_W_SCALING_ENABLE_NV dynamic state enabled then vkCmdSetViewportWScalingEnableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07641
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_SWIZZLE_NV dynamic state enabled then vkCmdSetViewportSwizzleNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07642
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_TO_COLOR_ENABLE_NV dynamic state enabled then vkCmdSetCoverageToColorEnableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07643
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_TO_COLOR_LOCATION_NV dynamic state enabled then vkCmdSetCoverageToColorLocationNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07644
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_MODULATION_MODE_NV dynamic state enabled then vkCmdSetCoverageModulationModeNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07645
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_MODULATION_TABLE_ENABLE_NV dynamic state enabled then vkCmdSetCoverageModulationTableEnableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07646
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_MODULATION_TABLE_NV dynamic state enabled then vkCmdSetCoverageModulationTableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07647
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SHADING_RATE_IMAGE_ENABLE_NV dynamic state enabled then vkCmdSetShadingRateImageEnableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07648
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_REPRESENTATIVE_FRAGMENT_TEST_ENABLE_NV dynamic state enabled then vkCmdSetRepresentativeFragmentTestEnableNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07649
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_REDUCTION_MODE_NV dynamic state enabled then vkCmdSetCoverageReductionModeNV must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-pColorBlendEnables-07470
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_ENABLE_EXT state enabled and the last call to vkCmdSetColorBlendEnableEXT set pColorBlendEnables for any attachment to VK_TRUE, then for those attachments in the subpass the corresponding image view’s format features must contain VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BLEND_BIT

  • VUID-vkCmdExecuteGeneratedCommandsNV-rasterizationSamples-07471
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, and the current subpass does not use any color and/or depth/stencil attachments, then the rasterizationSamples in the last call to vkCmdSetRasterizationSamplesEXT must follow the rules for a zero-attachment subpass

  • VUID-vkCmdExecuteGeneratedCommandsNV-samples-07472
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_MASK_EXT state enabled and the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state disabled, then the samples parameter in the last call to vkCmdSetSampleMaskEXT must be greater or equal to the VkPipelineMultisampleStateCreateInfo::rasterizationSamples parameter used to create the bound graphics pipeline

  • VUID-vkCmdExecuteGeneratedCommandsNV-samples-07473
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_MASK_EXT state and VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT states enabled, then the samples parameter in the last call to vkCmdSetSampleMaskEXT must be greater or equal to the rasterizationSamples parameter in the last call to vkCmdSetRasterizationSamplesEXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-rasterizationSamples-07474
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, and neither the VK_AMD_mixed_attachment_samples nor the VK_NV_framebuffer_mixed_samples extensions are enabled, then the rasterizationSamples in the last call to vkCmdSetRasterizationSamplesEXT must be the same as the current subpass color and/or depth/stencil attachments

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09211
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, and the current render pass instance includes a VkMultisampledRenderToSingleSampledInfoEXT structure with multisampledRenderToSingleSampledEnable equal to VK_TRUE, then the rasterizationSamples in the last call to vkCmdSetRasterizationSamplesEXT must be the same as the rasterizationSamples member of that structure

  • VUID-vkCmdExecuteGeneratedCommandsNV-firstAttachment-07476
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_ENABLE_EXT dynamic state enabled then vkCmdSetColorBlendEnableEXT must have been called in the current command buffer prior to this drawing command, and the attachments specified by the firstAttachment and attachmentCount parameters of vkCmdSetColorBlendEnableEXT calls must specify an enable for all active color attachments in the current subpass

  • VUID-vkCmdExecuteGeneratedCommandsNV-firstAttachment-07477
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_EQUATION_EXT dynamic state enabled then vkCmdSetColorBlendEquationEXT must have been called in the current command buffer prior to this drawing command, and the attachments specified by the firstAttachment and attachmentCount parameters of vkCmdSetColorBlendEquationEXT calls must specify the blend equations for all active color attachments in the current subpass where blending is enabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-firstAttachment-07478
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_WRITE_MASK_EXT dynamic state enabled then vkCmdSetColorWriteMaskEXT must have been called in the current command buffer prior to this drawing command, and the attachments specified by the firstAttachment and attachmentCount parameters of vkCmdSetColorWriteMaskEXT calls must specify the color write mask for all active color attachments in the current subpass

  • VUID-vkCmdExecuteGeneratedCommandsNV-firstAttachment-07479
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_ADVANCED_EXT dynamic state enabled then vkCmdSetColorBlendAdvancedEXT must have been called in the current command buffer prior to this drawing command, and the attachments specified by the firstAttachment and attachmentCount parameters of vkCmdSetColorBlendAdvancedEXT calls must specify the advanced blend equations for all active color attachments in the current subpass where blending is enabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-advancedBlendMaxColorAttachments-07480
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COLOR_BLEND_ADVANCED_EXT and VK_DYNAMIC_STATE_COLOR_BLEND_ENABLE_EXT dynamic states enabled and the last calls to vkCmdSetColorBlendEnableEXT and vkCmdSetColorBlendAdvancedEXT have enabled advanced blending, then the number of active color attachments in the current subpass must not exceed advancedBlendMaxColorAttachments

  • VUID-vkCmdExecuteGeneratedCommandsNV-primitivesGeneratedQueryWithNonZeroStreams-07481
    If the primitivesGeneratedQueryWithNonZeroStreams feature is not enabled and the VK_QUERY_TYPE_PRIMITIVES_GENERATED_EXT query is active, and the bound graphics pipeline was created with VK_DYNAMIC_STATE_RASTERIZATION_STREAM_EXT state enabled, the last call to vkCmdSetRasterizationStreamEXT must have set the rasterizationStream to zero

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsPerPixel-07482
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state enabled and the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state disabled, then the sampleLocationsPerPixel member of pSampleLocationsInfo in the last call to vkCmdSetSampleLocationsEXT must equal the rasterizationSamples member of the VkPipelineMultisampleStateCreateInfo structure the bound graphics pipeline has been created with

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsPerPixel-07483
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state enabled and the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, then the sampleLocationsPerPixel member of pSampleLocationsInfo in the last call to vkCmdSetSampleLocationsEXT must equal the rasterizationSamples parameter of the last call to vkCmdSetRasterizationSamplesEXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07484
    If the bound graphics pipeline was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, and sampleLocationsEnable was VK_TRUE in the last call to vkCmdSetSampleLocationsEnableEXT, and the current subpass has a depth/stencil attachment, then that attachment must have been created with the VK_IMAGE_CREATE_SAMPLE_LOCATIONS_COMPATIBLE_DEPTH_BIT_EXT bit set

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07485
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state enabled and the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, and if sampleLocationsEnable was VK_TRUE in the last call to vkCmdSetSampleLocationsEnableEXT, then the sampleLocationsInfo.sampleLocationGridSize.width in the last call to vkCmdSetSampleLocationsEXT must evenly divide VkMultisamplePropertiesEXT::sampleLocationGridSize.width as returned by vkGetPhysicalDeviceMultisamplePropertiesEXT with a samples parameter equaling rasterizationSamples

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07486
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state enabled and the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, and if sampleLocationsEnable was VK_TRUE in the last call to vkCmdSetSampleLocationsEnableEXT, then the sampleLocationsInfo.sampleLocationGridSize.height in the last call to vkCmdSetSampleLocationsEXT must evenly divide VkMultisamplePropertiesEXT::sampleLocationGridSize.height as returned by vkGetPhysicalDeviceMultisamplePropertiesEXT with a samples parameter equaling rasterizationSamples

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07487
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, and if sampleLocationsEnable was VK_TRUE in the last call to vkCmdSetSampleLocationsEnableEXT, the fragment shader code must not statically use the extended instruction InterpolateAtSample

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07936
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state disabled and the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, the sampleLocationsEnable member of a VkPipelineSampleLocationsStateCreateInfoEXT::sampleLocationsEnable in the bound graphics pipeline is VK_TRUE or VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, then, sampleLocationsInfo.sampleLocationGridSize.width must evenly divide VkMultisamplePropertiesEXT::sampleLocationGridSize.width as returned by vkGetPhysicalDeviceMultisamplePropertiesEXT with a samples parameter equaling the value of rasterizationSamples in the last call to vkCmdSetRasterizationSamplesEXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07937
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state disabled and the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, the sampleLocationsEnable member of a VkPipelineSampleLocationsStateCreateInfoEXT::sampleLocationsEnable in the bound graphics pipeline is VK_TRUE or VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, then, sampleLocationsInfo.sampleLocationGridSize.height must evenly divide VkMultisamplePropertiesEXT::sampleLocationGridSize.height as returned by vkGetPhysicalDeviceMultisamplePropertiesEXT with a samples parameter equaling the value of rasterizationSamples in the last call to vkCmdSetRasterizationSamplesEXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-sampleLocationsEnable-07938
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT state disabled and the VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT state enabled, the sampleLocationsEnable member of a VkPipelineSampleLocationsStateCreateInfoEXT::sampleLocationsEnable in the bound graphics pipeline is VK_TRUE or VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_ENABLE_EXT state enabled, then, sampleLocationsInfo.sampleLocationsPerPixel must equal rasterizationSamples in the last call to vkCmdSetRasterizationSamplesEXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-coverageModulationTableEnable-07488
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_MODULATION_TABLE_ENABLE_NV state enabled and the last call to vkCmdSetCoverageModulationTableEnableNV set coverageModulationTableEnable to VK_TRUE, then the coverageModulationTableCount parameter in the last call to vkCmdSetCoverageModulationTableNV must equal the current rasterizationSamples divided by the number of color samples in the current subpass

  • VUID-vkCmdExecuteGeneratedCommandsNV-rasterizationSamples-07489
    If the VK_NV_framebuffer_mixed_samples extension is enabled, and if current subpass has a depth/stencil attachment and depth test, stencil test, or depth bounds test are enabled in the currently bound pipeline state, then the current rasterizationSamples must be the same as the sample count of the depth/stencil attachment

  • VUID-vkCmdExecuteGeneratedCommandsNV-coverageToColorEnable-07490
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_TO_COLOR_ENABLE_NV state enabled and the last call to vkCmdSetCoverageToColorEnableNV set the coverageToColorEnable to VK_TRUE, then the current subpass must have a color attachment at the location selected by the last call to vkCmdSetCoverageToColorLocationNV coverageToColorLocation, with a VkFormat of VK_FORMAT_R8_UINT, VK_FORMAT_R8_SINT, VK_FORMAT_R16_UINT, VK_FORMAT_R16_SINT, VK_FORMAT_R32_UINT, or VK_FORMAT_R32_SINT

  • VUID-vkCmdExecuteGeneratedCommandsNV-coverageReductionMode-07491
    If this VK_NV_coverage_reduction_mode extension is enabled, the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_COVERAGE_TO_COLOR_ENABLE_NV and VK_DYNAMIC_STATE_RASTERIZATION_SAMPLES_EXT states enabled, the current coverage reduction mode coverageReductionMode, then the current rasterizationSamples, and the sample counts for the color and depth/stencil attachments (if the subpass has them) must be a valid combination returned by vkGetPhysicalDeviceSupportedFramebufferMixedSamplesCombinationsNV

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-07492
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT dynamic state enabled, but not the VK_DYNAMIC_STATE_VIEWPORT_SWIZZLE_NV dynamic state enabled, then the bound graphics pipeline must have been created with VkPipelineViewportSwizzleStateCreateInfoNV::viewportCount greater or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-viewportCount-07493
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VIEWPORT_WITH_COUNT and VK_DYNAMIC_STATE_VIEWPORT_SWIZZLE_NV dynamic states enabled then the viewportCount parameter in the last call to vkCmdSetViewportSwizzleNV must be greater than or equal to the viewportCount parameter in the last call to vkCmdSetViewportWithCount

  • VUID-vkCmdExecuteGeneratedCommandsNV-rasterizationSamples-07494
    If the VK_NV_framebuffer_mixed_samples extension is enabled, and if the current subpass has any color attachments and rasterizationSamples of the last call to vkCmdSetRasterizationSamplesEXT is greater than the number of color samples, then the pipeline sampleShadingEnable must be VK_FALSE

  • VUID-vkCmdExecuteGeneratedCommandsNV-stippledLineEnable-07495
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_STIPPLE_ENABLE_EXT or VK_DYNAMIC_STATE_LINE_RASTERIZATION_MODE_EXT dynamic states enabled, and if the current stippledLineEnable state is VK_TRUE and the current lineRasterizationMode state is VK_LINE_RASTERIZATION_MODE_RECTANGULAR_EXT, then the stippledRectangularLines feature must be enabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-stippledLineEnable-07496
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_STIPPLE_ENABLE_EXT or VK_DYNAMIC_STATE_LINE_RASTERIZATION_MODE_EXT dynamic states enabled, and if the current stippledLineEnable state is VK_TRUE and the current lineRasterizationMode state is VK_LINE_RASTERIZATION_MODE_BRESENHAM_EXT, then the stippledBresenhamLines feature must be enabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-stippledLineEnable-07497
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_STIPPLE_ENABLE_EXT or VK_DYNAMIC_STATE_LINE_RASTERIZATION_MODE_EXT dynamic states enabled, and if the current stippledLineEnable state is VK_TRUE and the current lineRasterizationMode state is VK_LINE_RASTERIZATION_MODE_RECTANGULAR_SMOOTH_EXT, then the stippledSmoothLines feature must be enabled

  • VUID-vkCmdExecuteGeneratedCommandsNV-stippledLineEnable-07498
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_LINE_STIPPLE_ENABLE_EXT or VK_DYNAMIC_STATE_LINE_RASTERIZATION_MODE_EXT dynamic states enabled, and if the current stippledLineEnable state is VK_TRUE and the current lineRasterizationMode state is VK_LINE_RASTERIZATION_MODE_DEFAULT_EXT, then the stippledRectangularLines feature must be enabled and VkPhysicalDeviceLimits::strictLines must be VK_TRUE

  • VUID-vkCmdExecuteGeneratedCommandsNV-conservativePointAndLineRasterization-07499
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_CONSERVATIVE_RASTERIZATION_MODE_EXT dynamic state enabled, conservativePointAndLineRasterization is not supported, and the effective primitive topology output by the last pre-rasterization shader stage is a line or point, then the conservativeRasterizationMode set by the last call to vkCmdSetConservativeRasterizationModeEXT must be VK_CONSERVATIVE_RASTERIZATION_MODE_DISABLED_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-stage-07073
    If the currently bound pipeline was created with the VkPipelineShaderStageCreateInfo::stage member of an element of VkGraphicsPipelineCreateInfo::pStages set to VK_SHADER_STAGE_VERTEX_BIT, VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT, VK_SHADER_STAGE_TESSELLATION_EVALUATION_BIT or VK_SHADER_STAGE_GEOMETRY_BIT, then Mesh Shader Queries must not be active

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07850
    If dynamic state was inherited from VkCommandBufferInheritanceViewportScissorInfoNV, it must be set in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09116
    If the currently bound graphics pipeline was created with VK_DYNAMIC_STATE_COLOR_WRITE_MASK_EXT, and the format of any color attachment is VK_FORMAT_E5B9G9R9_UFLOAT_PACK32, the corresponding element of the pColorWriteMasks parameter of vkCmdSetColorWriteMaskEXT must either include all of VK_COLOR_COMPONENT_R_BIT, VK_COLOR_COMPONENT_G_BIT, and VK_COLOR_COMPONENT_B_BIT, or none of them

  • VUID-vkCmdExecuteGeneratedCommandsNV-maxFragmentDualSrcAttachments-09239
    If blending is enabled for any attachment where either the source or destination blend factors for that attachment use the secondary color input, the maximum value of Location for any output attachment statically used in the Fragment Execution Model executed by this command must be less than maxFragmentDualSrcAttachments

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04007
    All vertex input bindings accessed via vertex input variables declared in the vertex shader entry point’s interface must have either valid or VK_NULL_HANDLE buffers bound

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04008
    If the nullDescriptor feature is not enabled, all vertex input bindings accessed via vertex input variables declared in the vertex shader entry point’s interface must not be VK_NULL_HANDLE

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02721
    For a given vertex buffer binding, any attribute data fetched must be entirely contained within the corresponding vertex buffer binding, as described in Vertex Input Description

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-07842
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_PRIMITIVE_TOPOLOGY dynamic state enabled then vkCmdSetPrimitiveTopology must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-dynamicPrimitiveTopologyUnrestricted-07500
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_PRIMITIVE_TOPOLOGY dynamic state enabled and the dynamicPrimitiveTopologyUnrestricted is VK_FALSE, then the primitiveTopology parameter of vkCmdSetPrimitiveTopology must be of the same topology class as the pipeline VkPipelineInputAssemblyStateCreateInfo::topology state

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04912
    If the bound graphics pipeline was created with both the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT and VK_DYNAMIC_STATE_VERTEX_INPUT_BINDING_STRIDE_EXT dynamic states enabled, then vkCmdSetVertexInputEXT must have been called in the current command buffer prior to this draw command

  • VUID-vkCmdExecuteGeneratedCommandsNV-pStrides-04913
    If the bound graphics pipeline was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_BINDING_STRIDE_EXT dynamic state enabled, but not the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, then vkCmdBindVertexBuffers2EXT must have been called in the current command buffer prior to this draw command, and the pStrides parameter of vkCmdBindVertexBuffers2EXT must not be NULL

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04914
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, then vkCmdSetVertexInputEXT must have been called in the current command buffer prior to this draw command

  • VUID-vkCmdExecuteGeneratedCommandsNV-Input-07939
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, then all variables with the Input storage class decorated with Location in the Vertex Execution Model OpEntryPoint must contain a location in VkVertexInputAttributeDescription2EXT::location

  • VUID-vkCmdExecuteGeneratedCommandsNV-Input-08734
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, then the numeric type associated with all Input variables of the corresponding Location in the Vertex Execution Model OpEntryPoint must be the same as VkVertexInputAttributeDescription2EXT::format

  • VUID-vkCmdExecuteGeneratedCommandsNV-format-08936
    If the currently bound graphics pipeline was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, and VkVertexInputAttributeDescription2EXT::format has a 64-bit component, then the scalar width associated with all Input variables of the corresponding Location in the Vertex Execution Model OpEntryPoint must be 64-bit

  • VUID-vkCmdExecuteGeneratedCommandsNV-format-08937
    If the currently bound graphics pipeline was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, and the scalar width associated with a Location decorated Input variable in the Vertex Execution Model OpEntryPoint is 64-bit, then the corresponding VkVertexInputAttributeDescription2EXT::format must have a 64-bit component

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-09203
    If the currently bound graphics pipeline was created with the VK_DYNAMIC_STATE_VERTEX_INPUT_EXT dynamic state enabled, and VkVertexInputAttributeDescription2EXT::format has a 64-bit component, then all Input variables at the corresponding Location in the Vertex Execution Model OpEntryPoint must not use components that are not present in the format

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04875
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_PATCH_CONTROL_POINTS_EXT dynamic state enabled then vkCmdSetPatchControlPointsEXT must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-04879
    If the bound graphics pipeline state was created with the VK_DYNAMIC_STATE_PRIMITIVE_RESTART_ENABLE dynamic state enabled then vkCmdSetPrimitiveRestartEnable must have been called in the current command buffer prior to this drawing command

  • VUID-vkCmdExecuteGeneratedCommandsNV-stage-06481
    The bound graphics pipeline must not have been created with the VkPipelineShaderStageCreateInfo::stage member of an element of VkGraphicsPipelineCreateInfo::pStages set to VK_SHADER_STAGE_TASK_BIT_EXT or VK_SHADER_STAGE_MESH_BIT_EXT

  • VUID-vkCmdExecuteGeneratedCommandsNV-commandBuffer-02970
    commandBuffer must not be a protected command buffer

  • VUID-vkCmdExecuteGeneratedCommandsNV-isPreprocessed-02908
    If isPreprocessed is VK_TRUE then vkCmdPreprocessGeneratedCommandsNV must have already been executed on the device, using the same pGeneratedCommandsInfo content as well as the content of the input buffers it references (all except VkGeneratedCommandsInfoNV::preprocessBuffer). Furthermore pGeneratedCommandsInfo`s indirectCommandsLayout must have been created with the VK_INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV bit set

  • VUID-vkCmdExecuteGeneratedCommandsNV-pipeline-02909
    VkGeneratedCommandsInfoNV::pipeline must match the current bound pipeline at VkGeneratedCommandsInfoNV::pipelineBindPoint

  • VUID-vkCmdExecuteGeneratedCommandsNV-None-02910
    Transform feedback must not be active

  • VUID-vkCmdExecuteGeneratedCommandsNV-deviceGeneratedCommands-02911
    The VkPhysicalDeviceDeviceGeneratedCommandsFeaturesNV::deviceGeneratedCommands feature must be enabled

Valid Usage (Implicit)
  • VUID-vkCmdExecuteGeneratedCommandsNV-commandBuffer-parameter
    commandBuffer must be a valid VkCommandBuffer handle

  • VUID-vkCmdExecuteGeneratedCommandsNV-pGeneratedCommandsInfo-parameter
    pGeneratedCommandsInfo must be a valid pointer to a valid VkGeneratedCommandsInfoNV structure

  • VUID-vkCmdExecuteGeneratedCommandsNV-commandBuffer-recording
    commandBuffer must be in the recording state

  • VUID-vkCmdExecuteGeneratedCommandsNV-commandBuffer-cmdpool
    The VkCommandPool that commandBuffer was allocated from must support graphics, or compute operations

  • VUID-vkCmdExecuteGeneratedCommandsNV-renderpass
    This command must only be called inside of a render pass instance

  • VUID-vkCmdExecuteGeneratedCommandsNV-videocoding
    This command must only be called outside of a video coding scope

Host Synchronization
  • Host access to commandBuffer must be externally synchronized

  • Host access to the VkCommandPool that commandBuffer was 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

Graphics
Compute

Action
Indirection

// Provided by VK_NV_device_generated_commands
typedef struct VkGeneratedCommandsInfoNV {
    VkStructureType                      sType;
    const void*                          pNext;
    VkPipelineBindPoint                  pipelineBindPoint;
    VkPipeline                           pipeline;
    VkIndirectCommandsLayoutNV           indirectCommandsLayout;
    uint32_t                             streamCount;
    const VkIndirectCommandsStreamNV*    pStreams;
    uint32_t                             sequencesCount;
    VkBuffer                             preprocessBuffer;
    VkDeviceSize                         preprocessOffset;
    VkDeviceSize                         preprocessSize;
    VkBuffer                             sequencesCountBuffer;
    VkDeviceSize                         sequencesCountOffset;
    VkBuffer                             sequencesIndexBuffer;
    VkDeviceSize                         sequencesIndexOffset;
} VkGeneratedCommandsInfoNV;
  • sType is a VkStructureType value identifying this structure.

  • pNext is NULL or a pointer to a structure extending this structure.

  • pipelineBindPoint is the VkPipelineBindPoint used for the pipeline.

  • pipeline is the VkPipeline used in the generation and execution process.

  • indirectCommandsLayout is the VkIndirectCommandsLayoutNV that provides the command sequence to generate.

  • streamCount defines the number of input streams

  • pStreams is a pointer to an array of streamCount VkIndirectCommandsStreamNV structures providing the input data for the tokens used in indirectCommandsLayout.

  • sequencesCount is the maximum number of sequences to reserve. If sequencesCountBuffer is VK_NULL_HANDLE, this is also the actual number of sequences generated.

  • preprocessBuffer is the VkBuffer that is used for preprocessing the input data for execution. If this structure is used with vkCmdExecuteGeneratedCommandsNV with its isPreprocessed set to VK_TRUE, then the preprocessing step is skipped and data is only read from this buffer. The contents and the layout of this buffer is opaque to applications and must not be modified or copied to another buffer for reuse.

  • preprocessOffset is the byte offset into preprocessBuffer where the preprocessed data is stored.

  • preprocessSize is the maximum byte size within the preprocessBuffer after the preprocessOffset that is available for preprocessing.

  • sequencesCountBuffer is a VkBuffer in which the actual number of sequences is provided as single uint32_t value.

  • sequencesCountOffset is the byte offset into sequencesCountBuffer where the count value is stored.

  • sequencesIndexBuffer is a VkBuffer that encodes the used sequence indices as uint32_t array.

  • sequencesIndexOffset is the byte offset into sequencesIndexBuffer where the index values start.

Valid Usage
  • VUID-VkGeneratedCommandsInfoNV-pipeline-02912
    The provided pipeline must match the pipeline bound at execution time

  • VUID-VkGeneratedCommandsInfoNV-indirectCommandsLayout-02913
    If the indirectCommandsLayout uses a token of VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV, then the pipeline must have been created with multiple shader groups

  • VUID-VkGeneratedCommandsInfoNV-indirectCommandsLayout-02914
    If the indirectCommandsLayout uses a token of VK_INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV, then the pipeline must have been created with VK_PIPELINE_CREATE_INDIRECT_BINDABLE_BIT_NV set in VkGraphicsPipelineCreateInfo::flags

  • VUID-VkGeneratedCommandsInfoNV-indirectCommandsLayout-02915
    If the indirectCommandsLayout uses a token of VK_INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV, then the pipeline`s VkPipelineLayout must match the VkIndirectCommandsLayoutTokenNV::pushconstantPipelineLayout

  • VUID-VkGeneratedCommandsInfoNV-streamCount-02916
    streamCount must match the indirectCommandsLayout’s streamCount

  • VUID-VkGeneratedCommandsInfoNV-sequencesCount-02917
    sequencesCount must be less or equal to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::maxIndirectSequenceCount and VkGeneratedCommandsMemoryRequirementsInfoNV::maxSequencesCount that was used to determine the preprocessSize

  • VUID-VkGeneratedCommandsInfoNV-preprocessBuffer-02918
    preprocessBuffer must have the VK_BUFFER_USAGE_INDIRECT_BUFFER_BIT bit set in its usage flag

  • VUID-VkGeneratedCommandsInfoNV-preprocessOffset-02919
    preprocessOffset must be aligned to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::minIndirectCommandsBufferOffsetAlignment

  • VUID-VkGeneratedCommandsInfoNV-preprocessBuffer-02971
    If preprocessBuffer is non-sparse then it must be bound completely and contiguously to a single VkDeviceMemory object

  • VUID-VkGeneratedCommandsInfoNV-preprocessSize-02920
    preprocessSize must be at least equal to the memory requirement`s size returned by vkGetGeneratedCommandsMemoryRequirementsNV using the matching inputs (indirectCommandsLayout, …​) as within this structure

  • VUID-VkGeneratedCommandsInfoNV-sequencesCountBuffer-02921
    sequencesCountBuffer can be set if the actual used count of sequences is sourced from the provided buffer. In that case the sequencesCount serves as upper bound

  • VUID-VkGeneratedCommandsInfoNV-sequencesCountBuffer-02922
    If sequencesCountBuffer is not VK_NULL_HANDLE, its usage flag must have the VK_BUFFER_USAGE_INDIRECT_BUFFER_BIT bit set

  • VUID-VkGeneratedCommandsInfoNV-sequencesCountBuffer-02923
    If sequencesCountBuffer is not VK_NULL_HANDLE, sequencesCountOffset must be aligned to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::minSequencesCountBufferOffsetAlignment

  • VUID-VkGeneratedCommandsInfoNV-sequencesCountBuffer-02972
    If sequencesCountBuffer is not VK_NULL_HANDLE and is non-sparse then it must be bound completely and contiguously to a single VkDeviceMemory object

  • VUID-VkGeneratedCommandsInfoNV-sequencesIndexBuffer-02924
    If indirectCommandsLayout’s VK_INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV is set, sequencesIndexBuffer must be set otherwise it must be VK_NULL_HANDLE

  • VUID-VkGeneratedCommandsInfoNV-sequencesIndexBuffer-02925
    If sequencesIndexBuffer is not VK_NULL_HANDLE, its usage flag must have the VK_BUFFER_USAGE_INDIRECT_BUFFER_BIT bit set

  • VUID-VkGeneratedCommandsInfoNV-sequencesIndexBuffer-02926
    If sequencesIndexBuffer is not VK_NULL_HANDLE, sequencesIndexOffset must be aligned to VkPhysicalDeviceDeviceGeneratedCommandsPropertiesNV::minSequencesIndexBufferOffsetAlignment

  • VUID-VkGeneratedCommandsInfoNV-sequencesIndexBuffer-02973
    If sequencesIndexBuffer is not VK_NULL_HANDLE and is non-sparse then it must be bound completely and contiguously to a single VkDeviceMemory object

  • VUID-VkGeneratedCommandsInfoNV-indirectCommandsLayout-07078
    If the indirectCommandsLayout uses a token of VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV, then the pipeline must contain a shader stage using the MeshNV Execution Model

  • VUID-VkGeneratedCommandsInfoNV-indirectCommandsLayout-07079
    If the indirectCommandsLayout uses a token of VK_INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_MESH_TASKS_NV, then the pipeline must contain a shader stage using the MeshEXT Execution Model

Valid Usage (Implicit)
  • VUID-VkGeneratedCommandsInfoNV-sType-sType
    sType must be VK_STRUCTURE_TYPE_GENERATED_COMMANDS_INFO_NV

  • VUID-VkGeneratedCommandsInfoNV-pNext-pNext
    pNext must be NULL

  • VUID-VkGeneratedCommandsInfoNV-pipelineBindPoint-parameter
    pipelineBindPoint must be a valid VkPipelineBindPoint value

  • VUID-VkGeneratedCommandsInfoNV-pipeline-parameter
    pipeline must be a valid VkPipeline handle

  • VUID-VkGeneratedCommandsInfoNV-indirectCommandsLayout-parameter
    indirectCommandsLayout must be a valid VkIndirectCommandsLayoutNV handle

  • VUID-VkGeneratedCommandsInfoNV-pStreams-parameter
    pStreams must be a valid pointer to an array of streamCount valid VkIndirectCommandsStreamNV structures

  • VUID-VkGeneratedCommandsInfoNV-preprocessBuffer-parameter
    preprocessBuffer must be a valid VkBuffer handle

  • VUID-VkGeneratedCommandsInfoNV-sequencesCountBuffer-parameter
    If sequencesCountBuffer is not VK_NULL_HANDLE, sequencesCountBuffer must be a valid VkBuffer handle

  • VUID-VkGeneratedCommandsInfoNV-sequencesIndexBuffer-parameter
    If sequencesIndexBuffer is not VK_NULL_HANDLE, sequencesIndexBuffer must be a valid VkBuffer handle

  • VUID-VkGeneratedCommandsInfoNV-streamCount-arraylength
    streamCount must be greater than 0

  • VUID-VkGeneratedCommandsInfoNV-commonparent
    Each of indirectCommandsLayout, pipeline, preprocessBuffer, sequencesCountBuffer, and sequencesIndexBuffer that are valid handles of non-ignored parameters must have been created, allocated, or retrieved from the same VkDevice

Referencing the functions defined in Indirect Commands Layout, vkCmdExecuteGeneratedCommandsNV behaves as:

uint32_t sequencesCount = sequencesCountBuffer ?
      min(maxSequencesCount, sequencesCountBuffer.load_uint32(sequencesCountOffset) :
      maxSequencesCount;


cmdProcessAllSequences(commandBuffer, pipeline,
                       indirectCommandsLayout, pIndirectCommandsStreams,
                       sequencesCount,
                       sequencesIndexBuffer, sequencesIndexOffset);

// The stateful commands within indirectCommandsLayout will not
// affect the state of subsequent commands in the target
// command buffer (cmd)
Note

It is important to note that the values of all state related to the pipelineBindPoint used are undefined after this command.

Commands can be preprocessed prior execution using the following command:

// Provided by VK_NV_device_generated_commands
void vkCmdPreprocessGeneratedCommandsNV(
    VkCommandBuffer                             commandBuffer,
    const VkGeneratedCommandsInfoNV*            pGeneratedCommandsInfo);
  • commandBuffer is the command buffer which does the preprocessing.

  • pGeneratedCommandsInfo is a pointer to a VkGeneratedCommandsInfoNV structure containing parameters affecting the preprocessing step.

Valid Usage
  • VUID-vkCmdPreprocessGeneratedCommandsNV-commandBuffer-02974
    commandBuffer must not be a protected command buffer

  • VUID-vkCmdPreprocessGeneratedCommandsNV-pGeneratedCommandsInfo-02927
    pGeneratedCommandsInfo`s indirectCommandsLayout must have been created with the VK_INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV bit set

  • VUID-vkCmdPreprocessGeneratedCommandsNV-deviceGeneratedCommands-02928
    The VkPhysicalDeviceDeviceGeneratedCommandsFeaturesNV::deviceGeneratedCommands feature must be enabled

Valid Usage (Implicit)
  • VUID-vkCmdPreprocessGeneratedCommandsNV-commandBuffer-parameter
    commandBuffer must be a valid VkCommandBuffer handle

  • VUID-vkCmdPreprocessGeneratedCommandsNV-pGeneratedCommandsInfo-parameter
    pGeneratedCommandsInfo must be a valid pointer to a valid VkGeneratedCommandsInfoNV structure

  • VUID-vkCmdPreprocessGeneratedCommandsNV-commandBuffer-recording
    commandBuffer must be in the recording state

  • VUID-vkCmdPreprocessGeneratedCommandsNV-commandBuffer-cmdpool
    The VkCommandPool that commandBuffer was allocated from must support graphics, or compute operations

  • VUID-vkCmdPreprocessGeneratedCommandsNV-renderpass
    This command must only be called outside of a render pass instance

  • VUID-vkCmdPreprocessGeneratedCommandsNV-videocoding
    This command must only be called outside of a video coding scope

Host Synchronization
  • Host access to commandBuffer must be externally synchronized

  • Host access to the VkCommandPool that commandBuffer was allocated from must be externally synchronized

Command Properties
Command Buffer Levels Render Pass Scope Video Coding Scope Supported Queue Types Command Type

Primary
Secondary

Outside

Outside

Graphics
Compute

Action