## C Specification

To import one or more existing Metal MTLTexture objects to underlie a VkImage object, include one or more VkImportMetalTextureInfoEXT structures in the pNext chain of the VkImageCreateInfo structure in a vkCreateImage command.

The VkImportMetalTextureInfoEXT structure is defined as:

// Provided by VK_EXT_metal_objects
typedef struct VkImportMetalTextureInfoEXT {
VkStructureType          sType;
const void*              pNext;
VkImageAspectFlagBits    plane;
MTLTexture_id            mtlTexture;
} VkImportMetalTextureInfoEXT;

## Members

• sType is the type of this structure.

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

• plane indicates the plane of the VkImage that the id<MTLTexture> object should be attached to.

• mtlTexture is a the Metal id<MTLTexture> object that is to underlie the VkImage plane.

## Description

The pNext chain must include one VkImportMetalTextureInfoEXT structure for each plane in the VkImage. The app must ensure that the configuration of the Metal id<MTLTexture> objects are compatible with the configuration of the VkImage. Failure to do so results in undefined behavior.

Valid Usage (Implicit)
• VUID-VkImportMetalTextureInfoEXT-sType-sType
sType must be VK_STRUCTURE_TYPE_IMPORT_METAL_TEXTURE_INFO_EXT

• VUID-VkImportMetalTextureInfoEXT-plane-parameter
plane must be a valid VkImageAspectFlagBits value