Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data ANativeWindow
- newtype VkAndroidSurfaceCreateFlagsKHR = VkAndroidSurfaceCreateFlagsKHR VkFlags
- pattern VK_STRUCTURE_TYPE_ANDROID_SURFACE_CREATE_INFO_KHR :: VkStructureType
- pattern VK_KHR_ANDROID_SURFACE_SPEC_VERSION :: Integral a => a
- pattern VK_KHR_ANDROID_SURFACE_EXTENSION_NAME :: (Eq a, IsString a) => a
- vkCreateAndroidSurfaceKHR :: ("instance" ::: VkInstance) -> ("pCreateInfo" ::: Ptr VkAndroidSurfaceCreateInfoKHR) -> ("pAllocator" ::: Ptr VkAllocationCallbacks) -> ("pSurface" ::: Ptr VkSurfaceKHR) -> IO VkResult
- data VkAndroidSurfaceCreateInfoKHR = VkAndroidSurfaceCreateInfoKHR {}
Documentation
data ANativeWindow Source #
Opaque data
newtype VkAndroidSurfaceCreateFlagsKHR Source #
Instances
pattern VK_KHR_ANDROID_SURFACE_SPEC_VERSION :: Integral a => a Source #
pattern VK_KHR_ANDROID_SURFACE_EXTENSION_NAME :: (Eq a, IsString a) => a Source #
vkCreateAndroidSurfaceKHR :: ("instance" ::: VkInstance) -> ("pCreateInfo" ::: Ptr VkAndroidSurfaceCreateInfoKHR) -> ("pAllocator" ::: Ptr VkAllocationCallbacks) -> ("pSurface" ::: Ptr VkSurfaceKHR) -> IO VkResult Source #
vkCreateAndroidSurfaceKHR - Create a
VkSurfaceKHR
object for an
Android native window
Parameters
instance
is the instance to associate the surface with.
pCreateInfo
is a pointer to an instance of theVkAndroidSurfaceCreateInfoKHR
structure containing parameters affecting the creation of the surface object.pAllocator
is the allocator used for host memory allocated for the surface object when there is no more specific allocator available (see Memory Allocation).pSurface
points to aVkSurfaceKHR
handle in which the created surface object is returned.
Description
During the lifetime of a surface created using a particular
ANativeWindow
handle any attempts to create another surface for the
same ANativeWindow
and any attempts to connect to the same
ANativeWindow
through other platform mechanisms will fail.
Note
In particular, only one VkSurfaceKHR
can exist at a time for a given
window. Similarly, a native window cannot be used by both a
VkSurfaceKHR
and EGLSurface
simultaneously.
If successful, vkCreateAndroidSurfaceKHR
increments the
ANativeWindow
’s reference count, and vkDestroySurfaceKHR
will
decrement it.
On Android, when a swapchain’s imageExtent
does not match the
surface’s currentExtent
, the presentable images will be scaled to the
surface’s dimensions during presentation. minImageExtent
is (1,1), and
maxImageExtent
is the maximum image size supported by the consumer.
For the system compositor, currentExtent
is the window size (i.e. the
consumer’s preferred size).
Valid Usage (Implicit)
instance
must be a validVkInstance
handle
pCreateInfo
must be a valid pointer to a validVkAndroidSurfaceCreateInfoKHR
structure- If
pAllocator
is notNULL
,pAllocator
must be a valid pointer to a validVkAllocationCallbacks
structure pSurface
must be a valid pointer to aVkSurfaceKHR
handle
Return Codes
[Success]
- VK_SUCCESS
[Failure]
- VK_ERROR_OUT_OF_HOST_MEMORY
VK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_NATIVE_WINDOW_IN_USE_KHR
See Also
VkAllocationCallbacks
,
VkAndroidSurfaceCreateInfoKHR
,
VkInstance
,
VkSurfaceKHR
data VkAndroidSurfaceCreateInfoKHR Source #
VkAndroidSurfaceCreateInfoKHR - Structure specifying parameters of a newly created Android surface object
Valid Usage
window
must point to a valid AndroidANativeWindow
.
Valid Usage (Implicit)
sType
must beVK_STRUCTURE_TYPE_ANDROID_SURFACE_CREATE_INFO_KHR
pNext
must beNULL
flags
must be0
See Also
VkAndroidSurfaceCreateFlagsKHR
,
VkStructureType
,
vkCreateAndroidSurfaceKHR
VkAndroidSurfaceCreateInfoKHR | |
|