VkBlitImageInfo2KHR(3)

# VkBlitImageInfo2KHR(3) Manual Page

## Name

VkBlitImageInfo2KHR - Structure specifying parameters of blit image command

Loading… please wait.

## C Specification

The `VkBlitImageInfo2KHR` structure is defined as:

    // Provided by VK_KHR_copy_commands2
    typedef struct VkBlitImageInfo2KHR {
        VkStructureType           sType;
        const void*               pNext;
        VkImage                   srcImage;
        VkImageLayout             srcImageLayout;
        VkImage                   dstImage;
        VkImageLayout             dstImageLayout;
        uint32_t                  regionCount;
        const VkImageBlit2KHR*    pRegions;
        VkFilter                  filter;
    } VkBlitImageInfo2KHR;

## Members

- `sType` is the type of this structure.

- `pNext` is `NULL` or a pointer to a structure extending this structure.

- `srcImage` is the source image.

- `srcImageLayout` is the layout of the source image subresources for the blit.

- `dstImage` is the destination image.

- `dstImageLayout` is the layout of the destination image subresources for the blit.

- `regionCount` is the number of regions to blit.

- `pRegions` is a pointer to an array of VkImageBlit2KHR structures specifying the regions to blit.

- `filter` is a VkFilter specifying the filter to apply if the blits require scaling.

## Description

Valid Usage

- VUID-VkBlitImageInfo2KHR-pRegions-00215
  The source region specified by each element of `pRegions` must be a region that is contained within `srcImage`

- VUID-VkBlitImageInfo2KHR-pRegions-00216
  The destination region specified by each element of `pRegions` must be a region that is contained within `dstImage`

- VUID-VkBlitImageInfo2KHR-pRegions-00217
  The union of all destination regions, specified by the elements of `pRegions`, must not overlap in memory with any texel that may be sampled during the blit operation

- VUID-VkBlitImageInfo2KHR-srcImage-01999
  The format features of `srcImage` must contain `VK_FORMAT_FEATURE_BLIT_SRC_BIT`

- VUID-VkBlitImageInfo2KHR-srcImage-01561
  `srcImage` must not use a format listed in [formats-requiring-sampler-ycbcr-conversion]

- VUID-VkBlitImageInfo2KHR-srcImage-00219
  `srcImage` must have been created with `VK_IMAGE_USAGE_TRANSFER_SRC_BIT` usage flag

- VUID-VkBlitImageInfo2KHR-srcImage-00220
  If `srcImage` is non-sparse then it must be bound completely and contiguously to a single `VkDeviceMemory` object

- VUID-VkBlitImageInfo2KHR-srcImageLayout-00221
  `srcImageLayout` must specify the layout of the image subresources of `srcImage` specified in `pRegions` at the time this command is executed on a `VkDevice`

- VUID-VkBlitImageInfo2KHR-srcImageLayout-01398
  `srcImageLayout` must be `VK_IMAGE_LAYOUT_SHARED_PRESENT_KHR`, `VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL` or `VK_IMAGE_LAYOUT_GENERAL`

- VUID-VkBlitImageInfo2KHR-dstImage-02000
  The format features of `dstImage` must contain `VK_FORMAT_FEATURE_BLIT_DST_BIT`

- VUID-VkBlitImageInfo2KHR-dstImage-01562
  `dstImage` must not use a format listed in [formats-requiring-sampler-ycbcr-conversion]

- VUID-VkBlitImageInfo2KHR-dstImage-00224
  `dstImage` must have been created with `VK_IMAGE_USAGE_TRANSFER_DST_BIT` usage flag

- VUID-VkBlitImageInfo2KHR-dstImage-00225
  If `dstImage` is non-sparse then it must be bound completely and contiguously to a single `VkDeviceMemory` object

- VUID-VkBlitImageInfo2KHR-dstImageLayout-00226
  `dstImageLayout` must specify the layout of the image subresources of `dstImage` specified in `pRegions` at the time this command is executed on a `VkDevice`

- VUID-VkBlitImageInfo2KHR-dstImageLayout-01399
  `dstImageLayout` must be `VK_IMAGE_LAYOUT_SHARED_PRESENT_KHR`, `VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL` or `VK_IMAGE_LAYOUT_GENERAL`

- VUID-VkBlitImageInfo2KHR-srcImage-00229
  If either of `srcImage` or `dstImage` was created with a signed integer VkFormat, the other must also have been created with a signed integer VkFormat

- VUID-VkBlitImageInfo2KHR-srcImage-00230
  If either of `srcImage` or `dstImage` was created with an unsigned integer VkFormat, the other must also have been created with an unsigned integer VkFormat

- VUID-VkBlitImageInfo2KHR-srcImage-00231
  If either of `srcImage` or `dstImage` was created with a depth/stencil format, the other must have exactly the same format

- VUID-VkBlitImageInfo2KHR-srcImage-00232
  If `srcImage` was created with a depth/stencil format, `filter` must be `VK_FILTER_NEAREST`

- VUID-VkBlitImageInfo2KHR-srcImage-00233
  `srcImage` must have been created with a `samples` value of `VK_SAMPLE_COUNT_1_BIT`

- VUID-VkBlitImageInfo2KHR-dstImage-00234
  `dstImage` must have been created with a `samples` value of `VK_SAMPLE_COUNT_1_BIT`

- VUID-VkBlitImageInfo2KHR-filter-02001
  If `filter` is `VK_FILTER_LINEAR`, then the format features of `srcImage` must contain `VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT`

- VUID-VkBlitImageInfo2KHR-filter-02002
  If `filter` is `VK_FILTER_CUBIC_EXT`, then the format features of `srcImage` must contain `VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_CUBIC_BIT_EXT`

- VUID-VkBlitImageInfo2KHR-filter-00237
  If `filter` is `VK_FILTER_CUBIC_EXT`, `srcImage` must be of type `VK_IMAGE_TYPE_2D`

- VUID-VkBlitImageInfo2KHR-srcSubresource-01705
  The `srcSubresource.mipLevel` member of each element of `pRegions` must be less than the `mipLevels` specified in VkImageCreateInfo when `srcImage` was created

- VUID-VkBlitImageInfo2KHR-dstSubresource-01706
  The `dstSubresource.mipLevel` member of each element of `pRegions` must be less than the `mipLevels` specified in VkImageCreateInfo when `dstImage` was created

- VUID-VkBlitImageInfo2KHR-srcSubresource-01707
  The `srcSubresource.baseArrayLayer` + `srcSubresource.layerCount` of each element of `pRegions` must be less than or equal to the `arrayLayers` specified in VkImageCreateInfo when `srcImage` was created

- VUID-VkBlitImageInfo2KHR-dstSubresource-01708
  The `dstSubresource.baseArrayLayer` + `dstSubresource.layerCount` of each element of `pRegions` must be less than or equal to the `arrayLayers` specified in VkImageCreateInfo when `dstImage` was created

- VUID-VkBlitImageInfo2KHR-dstImage-02545
  `dstImage` and `srcImage` must not have been created with `flags` containing `VK_IMAGE_CREATE_SUBSAMPLED_BIT_EXT`

- VUID-VkBlitImageInfo2KHR-srcImage-00240
  If either `srcImage` or `dstImage` is of type `VK_IMAGE_TYPE_3D`, then for each element of `pRegions`, `srcSubresource.baseArrayLayer` and `dstSubresource.baseArrayLayer` must each be `0`, and `srcSubresource.layerCount` and `dstSubresource.layerCount` must each be `1`.

- VUID-VkBlitImageInfo2KHR-aspectMask-00241
  For each element of `pRegions`, `srcSubresource.aspectMask` must specify aspects present in `srcImage`

- VUID-VkBlitImageInfo2KHR-aspectMask-00242
  For each element of `pRegions`, `dstSubresource.aspectMask` must specify aspects present in `dstImage`

- VUID-VkBlitImageInfo2KHR-srcOffset-00243
  For each element of `pRegions`, `srcOffset`[0].x and `srcOffset`[1].x must both be greater than or equal to `0` and less than or equal to the width of the specified `srcSubresource` of `srcImage`

- VUID-VkBlitImageInfo2KHR-srcOffset-00244
  For each element of `pRegions`, `srcOffset`[0].y and `srcOffset`[1].y must both be greater than or equal to `0` and less than or equal to the height of the specified `srcSubresource` of `srcImage`

- VUID-VkBlitImageInfo2KHR-srcImage-00245
  If `srcImage` is of type `VK_IMAGE_TYPE_1D`, then for each element of `pRegions`, `srcOffset`[0].y must be `0` and `srcOffset`[1].y must be `1`

- VUID-VkBlitImageInfo2KHR-srcOffset-00246
  For each element of `pRegions`, `srcOffset`[0].z and `srcOffset`[1].z must both be greater than or equal to `0` and less than or equal to the depth of the specified `srcSubresource` of `srcImage`

- VUID-VkBlitImageInfo2KHR-srcImage-00247
  If `srcImage` is of type `VK_IMAGE_TYPE_1D` or `VK_IMAGE_TYPE_2D`, then for each element of `pRegions`, `srcOffset`[0].z must be `0` and `srcOffset`[1].z must be `1`

- VUID-VkBlitImageInfo2KHR-dstOffset-00248
  For each element of `pRegions`, `dstOffset`[0].x and `dstOffset`[1].x must both be greater than or equal to `0` and less than or equal to the width of the specified `dstSubresource` of `dstImage`

- VUID-VkBlitImageInfo2KHR-dstOffset-00249
  For each element of `pRegions`, `dstOffset`[0].y and `dstOffset`[1].y must both be greater than or equal to `0` and less than or equal to the height of the specified `dstSubresource` of `dstImage`

- VUID-VkBlitImageInfo2KHR-dstImage-00250
  If `dstImage` is of type `VK_IMAGE_TYPE_1D`, then for each element of `pRegions`, `dstOffset`[0].y must be `0` and `dstOffset`[1].y must be `1`

- VUID-VkBlitImageInfo2KHR-dstOffset-00251
  For each element of `pRegions`, `dstOffset`[0].z and `dstOffset`[1].z must both be greater than or equal to `0` and less than or equal to the depth of the specified `dstSubresource` of `dstImage`

- VUID-VkBlitImageInfo2KHR-dstImage-00252
  If `dstImage` is of type `VK_IMAGE_TYPE_1D` or `VK_IMAGE_TYPE_2D`, then for each element of `pRegions`, `dstOffset`[0].z must be `0` and `dstOffset`[1].z must be `1`

- VUID-VkBlitImageInfo2KHR-pRegions-04561
  If any element of `pRegions` contains VkCopyCommandTransformInfoQCOM in its `pNext` chain, then `srcImage` and `dstImage` must not be a block-compressed image.

- VUID-VkBlitImageInfo2KHR-pRegions-04562
  If any element of `pRegions` contains VkCopyCommandTransformInfoQCOM in its `pNext` chain, then the `srcImage` must be of type `VK_IMAGE_TYPE_2D` and must not be a multi-planar format.

Valid Usage (Implicit)

- VUID-VkBlitImageInfo2KHR-sType-sType
  `sType` must be `VK_STRUCTURE_TYPE_BLIT_IMAGE_INFO_2_KHR`

- VUID-VkBlitImageInfo2KHR-pNext-pNext
  `pNext` must be `NULL`

- VUID-VkBlitImageInfo2KHR-srcImage-parameter
  `srcImage` must be a valid VkImage handle

- VUID-VkBlitImageInfo2KHR-srcImageLayout-parameter
  `srcImageLayout` must be a valid VkImageLayout value

- VUID-VkBlitImageInfo2KHR-dstImage-parameter
  `dstImage` must be a valid VkImage handle

- VUID-VkBlitImageInfo2KHR-dstImageLayout-parameter
  `dstImageLayout` must be a valid VkImageLayout value

- VUID-VkBlitImageInfo2KHR-pRegions-parameter
  `pRegions` must be a valid pointer to an array of `regionCount` valid VkImageBlit2KHR structures

- VUID-VkBlitImageInfo2KHR-filter-parameter
  `filter` must be a valid VkFilter value

- VUID-VkBlitImageInfo2KHR-regionCount-arraylength
  `regionCount` must be greater than `0`

- VUID-VkBlitImageInfo2KHR-commonparent
  Both of `dstImage`, and `srcImage` must have been created, allocated, or retrieved from the same VkDevice

## See Also

VkFilter, VkImage, VkImageBlit2KHR, VkImageLayout, VkStructureType, vkCmdBlitImage2KHR

## 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

Copyright (c) 2014-2020 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0