C Specification

The VkCopyBufferInfo2KHR structure is defined as:

// Provided by VK_KHR_copy_commands2
typedef struct VkCopyBufferInfo2KHR {
    VkStructureType            sType;
    const void*                pNext;
    VkBuffer                   srcBuffer;
    VkBuffer                   dstBuffer;
    uint32_t                   regionCount;
    const VkBufferCopy2KHR*    pRegions;
} VkCopyBufferInfo2KHR;

Members

  • sType is the type of this structure.

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

  • srcBuffer is the source buffer.

  • dstBuffer is the destination buffer.

  • regionCount is the number of regions to copy.

  • pRegions is a pointer to an array of VkBufferCopy2KHR structures specifying the regions to copy.

Description

Members defined by this structure with the same name as parameters in vkCmdCopyBuffer have the identical effect to those parameters; the child structure VkBufferCopy2KHR is a variant of VkBufferCopy which includes sType and pNext parameters, allowing it to be extended.

Valid Usage
  • VUID-VkCopyBufferInfo2KHR-srcOffset-00113
    The srcOffset member of each element of pRegions must be less than the size of srcBuffer

  • VUID-VkCopyBufferInfo2KHR-dstOffset-00114
    The dstOffset member of each element of pRegions must be less than the size of dstBuffer

  • VUID-VkCopyBufferInfo2KHR-size-00115
    The size member of each element of pRegions must be less than or equal to the size of srcBuffer minus srcOffset

  • VUID-VkCopyBufferInfo2KHR-size-00116
    The size member of each element of pRegions must be less than or equal to the size of dstBuffer minus dstOffset

  • VUID-VkCopyBufferInfo2KHR-pRegions-00117
    The union of the source regions, and the union of the destination regions, specified by the elements of pRegions, must not overlap in memory

  • VUID-VkCopyBufferInfo2KHR-srcBuffer-00118
    srcBuffer must have been created with VK_BUFFER_USAGE_TRANSFER_SRC_BIT usage flag

  • VUID-VkCopyBufferInfo2KHR-srcBuffer-00119
    If srcBuffer is non-sparse then it must be bound completely and contiguously to a single VkDeviceMemory object

  • VUID-VkCopyBufferInfo2KHR-dstBuffer-00120
    dstBuffer must have been created with VK_BUFFER_USAGE_TRANSFER_DST_BIT usage flag

  • VUID-VkCopyBufferInfo2KHR-dstBuffer-00121
    If dstBuffer is non-sparse then it must be bound completely and contiguously to a single VkDeviceMemory object

Valid Usage (Implicit)
  • VUID-VkCopyBufferInfo2KHR-sType-sType
    sType must be VK_STRUCTURE_TYPE_COPY_BUFFER_INFO_2_KHR

  • VUID-VkCopyBufferInfo2KHR-pNext-pNext
    pNext must be NULL

  • VUID-VkCopyBufferInfo2KHR-srcBuffer-parameter
    srcBuffer must be a valid VkBuffer handle

  • VUID-VkCopyBufferInfo2KHR-dstBuffer-parameter
    dstBuffer must be a valid VkBuffer handle

  • VUID-VkCopyBufferInfo2KHR-pRegions-parameter
    pRegions must be a valid pointer to an array of regionCount valid VkBufferCopy2KHR structures

  • VUID-VkCopyBufferInfo2KHR-regionCount-arraylength
    regionCount must be greater than 0

  • VUID-VkCopyBufferInfo2KHR-commonparent
    Both of dstBuffer, and srcBuffer must have been created, allocated, or retrieved from the same VkDevice

See Also

Document Notes

For more information, see the Vulkan Specification

This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.

Copyright 2014-2021 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0