1// Copyright 2014-2023 The Khronos Group Inc.
2//
3// SPDX-License-Identifier: CC-BY-4.0
4
5[[platformCreateSurface_streamdescriptor]]
6=== Google Games Platform
7
8[open,refpage='vkCreateStreamDescriptorSurfaceGGP',desc='Create a slink:VkSurfaceKHR object for a Google Games Platform stream',type='protos']
9--
10:refpage: vkCreateStreamDescriptorSurfaceGGP
11
12To create a sname:VkSurfaceKHR object for a Google Games Platform stream
13descriptor, call:
14
15include::{generated}/api/protos/vkCreateStreamDescriptorSurfaceGGP.adoc[]
16
17  * pname:instance is the instance to associate with the surface.
18  * pname:pCreateInfo is a pointer to a
19    sname:VkStreamDescriptorSurfaceCreateInfoGGP structure containing
20    parameters that affect the creation of the surface object.
21  * pname:pAllocator is the allocator used for host memory allocated for the
22    surface object when there is no more specific allocator available (see
23    <<memory-allocation,Memory Allocation>>).
24  * pname:pSurface is a pointer to a slink:VkSurfaceKHR handle in which the
25    created surface object is returned.
26
27include::{generated}/validity/protos/vkCreateStreamDescriptorSurfaceGGP.adoc[]
28--
29
30[open,refpage='VkStreamDescriptorSurfaceCreateInfoGGP',desc='Structure specifying parameters of a newly created Google Games Platform stream surface object',type='structs']
31--
32The sname:VkStreamDescriptorSurfaceCreateInfoGGP structure is defined as:
33
34include::{generated}/api/structs/VkStreamDescriptorSurfaceCreateInfoGGP.adoc[]
35
36  * pname:sType is a elink:VkStructureType value identifying this structure.
37  * pname:pNext is `NULL` or a pointer to a structure extending this
38    structure.
39  * pname:flags is reserved for future use.
40  * pname:streamDescriptor is a code:GgpStreamDescriptor referring to the
41    GGP stream descriptor to associate with the surface.
42
43.Valid Usage
44****
45  * [[VUID-VkStreamDescriptorSurfaceCreateInfoGGP-streamDescriptor-02681]]
46    pname:streamDescriptor must: be a valid code:GgpStreamDescriptor
47****
48
49include::{generated}/validity/structs/VkStreamDescriptorSurfaceCreateInfoGGP.adoc[]
50--
51
52On Google Games Platform, the surface extents are dynamic.
53The pname:minImageExtent will never be greater than 1080p and the
54pname:maxImageExtent will never be less than 1080p.
55The pname:currentExtent will reflect the current optimal resolution.
56
57ifdef::VK_KHR_swapchain[]
58Applications are expected to choose an appropriate size for the swapchain's
59pname:imageExtent, within the bounds of the surface.
60Using the surface's pname:currentExtent will offer the best performance and
61quality.
62When a swapchain's pname:imageExtent does not match the surface's
63pname:currentExtent, the presentable images are scaled to the surface's
64dimensions during presentation if possible and ename:VK_SUBOPTIMAL_KHR is
65returned, otherwise presentation fails with ename:VK_ERROR_OUT_OF_DATE_KHR.
66endif::VK_KHR_swapchain[]
67
68[open,refpage='VkStreamDescriptorSurfaceCreateFlagsGGP',desc='Reserved for future use',type='flags']
69--
70include::{generated}/api/flags/VkStreamDescriptorSurfaceCreateFlagsGGP.adoc[]
71
72tname:VkStreamDescriptorSurfaceCreateFlagsGGP is a bitmask type for setting
73a mask, but is currently reserved for future use.
74--
75