platformCreateSurface_ios.txt
1 [[platformCreateSurface_ios,platformCreateSurface_ios]] 2 3 === iOS Platform 4 5 [open,refpage='vkCreateIOSSurfaceMVK',desc='Create a VkSurfaceKHR object for an iOS UIView',type='protos'] 6 -- 7 8 To create a sname:VkSurfaceKHR object for an iOS code:UIView, call: 9 10 include::{generated}/api/protos/vkCreateIOSSurfaceMVK.txt[] 11 12 * pname:instance is the instance with which to associate the surface. 13 * pname:pCreateInfo is a pointer to an instance of the 14 slink:VkIOSSurfaceCreateInfoMVK structure containing parameters 15 affecting the creation of the surface object. 16 * pname:pAllocator is the allocator used for host memory allocated for the 17 surface object when there is no more specific allocator available (see 18 <<memory-allocation,Memory Allocation>>). 19 * pname:pSurface points to a slink:VkSurfaceKHR handle in which the 20 created surface object is returned. 21 22 include::{generated}/validity/protos/vkCreateIOSSurfaceMVK.txt[] 23 -- 24 25 [open,refpage='VkIOSSurfaceCreateInfoMVK',desc='Structure specifying parameters of a newly created iOS surface object',type='structs'] 26 -- 27 28 The slink:VkIOSSurfaceCreateInfoMVK structure is defined as: 29 30 include::{generated}/api/structs/VkIOSSurfaceCreateInfoMVK.txt[] 31 32 * pname:sType is the type of this structure. 33 * pname:pNext is `NULL` or a pointer to an extension-specific structure. 34 * pname:flags is reserved for future use. 35 * pname:pView is a reference to a code:UIView object which will display 36 this surface. 37 This code:UIView must: be backed by a code:CALayer instance of type 38 dlink:CAMetalLayer. 39 40 .Valid Usage 41 **** 42 * [[VUID-VkIOSSurfaceCreateInfoMVK-pView-01316]] 43 pname:pView must: be a valid code:UIView and must: be backed by a 44 code:CALayer instance of type dlink:CAMetalLayer. 45 **** 46 47 include::{generated}/validity/structs/VkIOSSurfaceCreateInfoMVK.txt[] 48 -- 49