| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Graphics.Vulkan.Extensions.VK_KHR_swapchain
- newtype VkSwapchainCreateFlagBitsKHR = VkSwapchainCreateFlagBitsKHR VkFlags
- newtype VkDeviceGroupPresentModeFlagBitsKHR = VkDeviceGroupPresentModeFlagBitsKHR VkFlags
- pattern VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR
- pattern VK_DEVICE_GROUP_PRESENT_MODE_REMOTE_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR
- pattern VK_DEVICE_GROUP_PRESENT_MODE_SUM_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR
- pattern VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR
- pattern VK_IMAGE_LAYOUT_PRESENT_SRC_KHR :: VkImageLayout
- pattern VK_SUBOPTIMAL_KHR :: VkResult
- pattern VK_ERROR_OUT_OF_DATE_KHR :: VkResult
- pattern VK_STRUCTURE_TYPE_SWAPCHAIN_CREATE_INFO_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_PRESENT_INFO_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_DEVICE_GROUP_PRESENT_CAPABILITIES_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_IMAGE_SWAPCHAIN_CREATE_INFO_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_BIND_IMAGE_MEMORY_SWAPCHAIN_INFO_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_ACQUIRE_NEXT_IMAGE_INFO_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_DEVICE_GROUP_PRESENT_INFO_KHR :: VkStructureType
- pattern VK_STRUCTURE_TYPE_DEVICE_GROUP_SWAPCHAIN_CREATE_INFO_KHR :: VkStructureType
- pattern VK_OBJECT_TYPE_SWAPCHAIN_KHR :: VkObjectType
- pattern VK_SWAPCHAIN_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT_KHR :: VkSwapchainCreateFlagBitsKHR
- pattern VK_SWAPCHAIN_CREATE_PROTECTED_BIT_KHR :: VkSwapchainCreateFlagBitsKHR
- pattern VK_KHR_SWAPCHAIN_SPEC_VERSION :: Integral a => a
- pattern VK_KHR_SWAPCHAIN_EXTENSION_NAME :: (Eq a, IsString a) => a
- type VkSwapchainKHR = Ptr VkSwapchainKHR_T
- vkCreateSwapchainKHR :: ("device" ::: VkDevice) -> ("pCreateInfo" ::: Ptr VkSwapchainCreateInfoKHR) -> ("pAllocator" ::: Ptr VkAllocationCallbacks) -> ("pSwapchain" ::: Ptr VkSwapchainKHR) -> IO VkResult
- vkDestroySwapchainKHR :: ("device" ::: VkDevice) -> ("swapchain" ::: VkSwapchainKHR) -> ("pAllocator" ::: Ptr VkAllocationCallbacks) -> IO ()
- vkGetSwapchainImagesKHR :: ("device" ::: VkDevice) -> ("swapchain" ::: VkSwapchainKHR) -> ("pSwapchainImageCount" ::: Ptr Word32) -> ("pSwapchainImages" ::: Ptr VkImage) -> IO VkResult
- vkAcquireNextImageKHR :: ("device" ::: VkDevice) -> ("swapchain" ::: VkSwapchainKHR) -> ("timeout" ::: Word64) -> ("semaphore" ::: VkSemaphore) -> ("fence" ::: VkFence) -> ("pImageIndex" ::: Ptr Word32) -> IO VkResult
- vkQueuePresentKHR :: ("queue" ::: VkQueue) -> ("pPresentInfo" ::: Ptr VkPresentInfoKHR) -> IO VkResult
- vkGetDeviceGroupPresentCapabilitiesKHR :: ("device" ::: VkDevice) -> ("pDeviceGroupPresentCapabilities" ::: Ptr VkDeviceGroupPresentCapabilitiesKHR) -> IO VkResult
- vkGetDeviceGroupSurfacePresentModesKHR :: ("device" ::: VkDevice) -> ("surface" ::: VkSurfaceKHR) -> ("pModes" ::: Ptr VkDeviceGroupPresentModeFlagsKHR) -> IO VkResult
- vkAcquireNextImage2KHR :: ("device" ::: VkDevice) -> ("pAcquireInfo" ::: Ptr VkAcquireNextImageInfoKHR) -> ("pImageIndex" ::: Ptr Word32) -> IO VkResult
- vkGetPhysicalDevicePresentRectanglesKHR :: ("physicalDevice" ::: VkPhysicalDevice) -> ("surface" ::: VkSurfaceKHR) -> ("pRectCount" ::: Ptr Word32) -> ("pRects" ::: Ptr VkRect2D) -> IO VkResult
- data VkSwapchainCreateInfoKHR = VkSwapchainCreateInfoKHR {
- vkSType :: VkStructureType
- vkPNext :: Ptr ()
- vkFlags :: VkSwapchainCreateFlagsKHR
- vkSurface :: VkSurfaceKHR
- vkMinImageCount :: Word32
- vkImageFormat :: VkFormat
- vkImageColorSpace :: VkColorSpaceKHR
- vkImageExtent :: VkExtent2D
- vkImageArrayLayers :: Word32
- vkImageUsage :: VkImageUsageFlags
- vkImageSharingMode :: VkSharingMode
- vkQueueFamilyIndexCount :: Word32
- vkPQueueFamilyIndices :: Ptr Word32
- vkPreTransform :: VkSurfaceTransformFlagBitsKHR
- vkCompositeAlpha :: VkCompositeAlphaFlagBitsKHR
- vkPresentMode :: VkPresentModeKHR
- vkClipped :: VkBool32
- vkOldSwapchain :: VkSwapchainKHR
- data VkPresentInfoKHR = VkPresentInfoKHR {}
- data VkDeviceGroupPresentCapabilitiesKHR = VkDeviceGroupPresentCapabilitiesKHR {}
- data VkImageSwapchainCreateInfoKHR = VkImageSwapchainCreateInfoKHR {
- vkSType :: VkStructureType
- vkPNext :: Ptr ()
- vkSwapchain :: VkSwapchainKHR
- data VkBindImageMemorySwapchainInfoKHR = VkBindImageMemorySwapchainInfoKHR {
- vkSType :: VkStructureType
- vkPNext :: Ptr ()
- vkSwapchain :: VkSwapchainKHR
- vkImageIndex :: Word32
- data VkAcquireNextImageInfoKHR = VkAcquireNextImageInfoKHR {}
- data VkDeviceGroupPresentInfoKHR = VkDeviceGroupPresentInfoKHR {}
- data VkDeviceGroupSwapchainCreateInfoKHR = VkDeviceGroupSwapchainCreateInfoKHR {}
- type VkSwapchainCreateFlagsKHR = VkSwapchainCreateFlagBitsKHR
- type VkDeviceGroupPresentModeFlagsKHR = VkDeviceGroupPresentModeFlagBitsKHR
Documentation
newtype VkSwapchainCreateFlagBitsKHR Source #
VkSwapchainCreateFlagBitsKHR - Bitmask controlling swapchain creation
See Also
Constructors
| VkSwapchainCreateFlagBitsKHR VkFlags |
Instances
newtype VkDeviceGroupPresentModeFlagBitsKHR Source #
VkDeviceGroupPresentModeFlagBitsKHR - Bitmask specifying supported device group present modes
See Also
VkDeviceGroupPresentInfoKHR, VkDeviceGroupPresentModeFlagsKHR
Constructors
| VkDeviceGroupPresentModeFlagBitsKHR VkFlags |
Instances
pattern VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR Source #
VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR specifies that any physical
device with a presentation engine can present its own swapchain
images.
pattern VK_DEVICE_GROUP_PRESENT_MODE_REMOTE_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR Source #
VK_DEVICE_GROUP_PRESENT_MODE_REMOTE_BIT_KHR specifies that any
physical device with a presentation engine can present swapchain
images from any physical device in its presentMask.
pattern VK_DEVICE_GROUP_PRESENT_MODE_SUM_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR Source #
VK_DEVICE_GROUP_PRESENT_MODE_SUM_BIT_KHR specifies that any physical
device with a presentation engine can present the sum of swapchain
images from any physical devices in its presentMask.
pattern VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHR :: VkDeviceGroupPresentModeFlagBitsKHR Source #
VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHR specifies that
multiple physical devices with a presentation engine can each present
their own swapchain images.
pattern VK_IMAGE_LAYOUT_PRESENT_SRC_KHR :: VkImageLayout Source #
pattern VK_SUBOPTIMAL_KHR :: VkResult Source #
pattern VK_ERROR_OUT_OF_DATE_KHR :: VkResult Source #
pattern VK_STRUCTURE_TYPE_PRESENT_INFO_KHR :: VkStructureType Source #
pattern VK_OBJECT_TYPE_SWAPCHAIN_KHR :: VkObjectType Source #
pattern VK_SWAPCHAIN_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT_KHR :: VkSwapchainCreateFlagBitsKHR Source #
VK_SWAPCHAIN_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT_KHR specifies that
images created from the swapchain (i.e. with the swapchain member of
VkImageSwapchainCreateInfoKHR set to this swapchain’s handle) must
use VK_IMAGE_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT.
pattern VK_KHR_SWAPCHAIN_SPEC_VERSION :: Integral a => a Source #
pattern VK_KHR_SWAPCHAIN_EXTENSION_NAME :: (Eq a, IsString a) => a Source #
type VkSwapchainKHR = Ptr VkSwapchainKHR_T Source #
VkSwapchainKHR - Opaque handle to a swapchain object
Description
A swapchain is an abstraction for an array of presentable images that
are associated with a surface. The presentable images are represented by
VkImage objects created by the platform. One image (which can be an
array image for multiview/stereoscopic-3D surfaces) is displayed at a
time, but multiple images can be queued for presentation. An
application renders to the image, and then queues the image for
presentation to the surface.
A native window cannot be associated with more than one swapchain at a time. Further, swapchains cannot be created for native windows that have a non-Vulkan graphics API surface associated with them.
Note
The presentation engine is an abstraction for the platform’s compositor or display engine.
The presentation engine may be synchronous or asynchronous with respect to the application and/or logical device.
Some implementations may use the device’s graphics queue or dedicated presentation hardware to perform presentation.
The presentable images of a swapchain are owned by the presentation
engine. An application can acquire use of a presentable image from the
presentation engine. Use of a presentable image must occur only after
the image is returned by vkAcquireNextImageKHR, and before it is
presented by vkQueuePresentKHR. This includes transitioning the image
layout and rendering commands.
An application can acquire use of a presentable image with
vkAcquireNextImageKHR. After acquiring a presentable image and before
modifying it, the application must use a synchronization primitive to
ensure that the presentation engine has finished reading from the image.
The application can then transition the image’s layout, queue
rendering commands to it, etc. Finally, the application presents the
image with vkQueuePresentKHR, which releases the acquisition of the
image.
The presentation engine controls the order in which presentable images are acquired for use by the application.
Note
This allows the platform to handle situations which require out-of-order return of images after presentation. At the same time, it allows the application to generate command buffers referencing all of the images in the swapchain at initialization time, rather than in its main loop.
See Also
VkAcquireNextImageInfoKHR, VkBindImageMemorySwapchainInfoKHR,
VkImageSwapchainCreateInfoKHR, VkPresentInfoKHR,
VkSwapchainCreateInfoKHR, vkAcquireNextImageKHR,
vkCreateSharedSwapchainsKHR,
vkCreateSwapchainKHR, vkDestroySwapchainKHR,
vkGetPastPresentationTimingGOOGLE,
vkGetRefreshCycleDurationGOOGLE,
vkGetSwapchainCounterEXT,
vkGetSwapchainImagesKHR,
vkGetSwapchainStatusKHR,
vkSetHdrMetadataEXT
vkCreateSwapchainKHR :: ("device" ::: VkDevice) -> ("pCreateInfo" ::: Ptr VkSwapchainCreateInfoKHR) -> ("pAllocator" ::: Ptr VkAllocationCallbacks) -> ("pSwapchain" ::: Ptr VkSwapchainKHR) -> IO VkResult Source #
vkCreateSwapchainKHR - Create a swapchain
Parameters
deviceis the device to create the swapchain for.
pCreateInfois a pointer to an instance of theVkSwapchainCreateInfoKHRstructure specifying the parameters of the created swapchain.pAllocatoris the allocator used for host memory allocated for the swapchain object when there is no more specific allocator available (see Memory Allocation).pSwapchainis a pointer to aVkSwapchainKHRhandle in which the created swapchain object will be returned.
Description
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
pCreateInfomust be a valid pointer to a validVkSwapchainCreateInfoKHRstructure- If
pAllocatoris notNULL,pAllocatormust be a valid pointer to a validVkAllocationCallbacksstructure pSwapchainmust be a valid pointer to aVkSwapchainKHRhandle
Host Synchronization
- Host access to
pCreateInfo.surfacemust be externally synchronized
- Host access to
pCreateInfo.oldSwapchainmust be externally synchronized
Return Codes
- Success
- -
VK_SUCCESS
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_DEVICE_LOST
VK_ERROR_SURFACE_LOST_KHR
VK_ERROR_NATIVE_WINDOW_IN_USE_KHR
See Also
VkAllocationCallbacks,
VkDevice,
VkSwapchainCreateInfoKHR, VkSwapchainKHR
vkDestroySwapchainKHR :: ("device" ::: VkDevice) -> ("swapchain" ::: VkSwapchainKHR) -> ("pAllocator" ::: Ptr VkAllocationCallbacks) -> IO () Source #
vkDestroySwapchainKHR - Destroy a swapchain object
Parameters
deviceis theVkDeviceassociated withswapchain.
swapchainis the swapchain to destroy.pAllocatoris the allocator used for host memory allocated for the swapchain object when there is no more specific allocator available (see Memory Allocation).
Description
The application must not destroy a swapchain until after completion of
all outstanding operations on images that were acquired from the
swapchain. swapchain and all associated VkImage handles are
destroyed, and must not be acquired or used any more by the
application. The memory of each VkImage will only be freed after that
image is no longer used by the presentation engine. For example, if one
image of the swapchain is being displayed in a window, the memory for
that image may not be freed until the window is destroyed, or another
swapchain is created for the window. Destroying the swapchain does not
invalidate the parent VkSurfaceKHR, and a new swapchain can be
created with it.
When a swapchain associated with a display surface is destroyed, if the image most recently presented to the display surface is from the swapchain being destroyed, then either any display resources modified by presenting images from any swapchain associated with the display surface must be reverted by the implementation to their state prior to the first present performed on one of these swapchains, or such resources must be left in their current state.
Valid Usage
- All uses of presentable images acquired from
swapchainmust have completed execution
- If
VkAllocationCallbackswere provided whenswapchainwas created, a compatible set of callbacks must be provided here - If no
VkAllocationCallbackswere provided whenswapchainwas created,pAllocatormust beNULL
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
- If
swapchainis notVK_NULL_HANDLE,swapchainmust be a validVkSwapchainKHRhandle - If
pAllocatoris notNULL,pAllocatormust be a valid pointer to a validVkAllocationCallbacksstructure - Both of
device, andswapchainthat are valid handles must have been created, allocated, or retrieved from the sameVkInstance
Host Synchronization
- Host access to
swapchainmust be externally synchronized
See Also
vkGetSwapchainImagesKHR :: ("device" ::: VkDevice) -> ("swapchain" ::: VkSwapchainKHR) -> ("pSwapchainImageCount" ::: Ptr Word32) -> ("pSwapchainImages" ::: Ptr VkImage) -> IO VkResult Source #
vkGetSwapchainImagesKHR - Obtain the array of presentable images associated with a swapchain
Parameters
deviceis the device associated withswapchain.
swapchainis the swapchain to query.pSwapchainImageCountis a pointer to an integer related to the number of presentable images available or queried, as described below.pSwapchainImagesis eitherNULLor a pointer to an array ofVkImagehandles.
Description
If pSwapchainImages is NULL, then the number of presentable images
for swapchain is returned in pSwapchainImageCount. Otherwise,
pSwapchainImageCount must point to a variable set by the user to the
number of elements in the pSwapchainImages array, and on return the
variable is overwritten with the number of structures actually written
to pSwapchainImages. If the value of pSwapchainImageCount is less
than the number of presentable images for swapchain, at most
pSwapchainImageCount structures will be written. If
pSwapchainImageCount is smaller than the number of presentable images
for swapchain, VK_INCOMPLETE will be returned instead of
VK_SUCCESS to indicate that not all the available values were
returned.
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
swapchainmust be a validVkSwapchainKHRhandlepSwapchainImageCountmust be a valid pointer to auint32_tvalue- If the value referenced by
pSwapchainImageCountis not0, andpSwapchainImagesis notNULL,pSwapchainImagesmust be a valid pointer to an array ofpSwapchainImageCountVkImagehandles - Both of
device, andswapchainmust have been created, allocated, or retrieved from the sameVkInstance
Return Codes
- Success
- -
VK_SUCCESSVK_INCOMPLETE
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
See Also
vkAcquireNextImageKHR :: ("device" ::: VkDevice) -> ("swapchain" ::: VkSwapchainKHR) -> ("timeout" ::: Word64) -> ("semaphore" ::: VkSemaphore) -> ("fence" ::: VkFence) -> ("pImageIndex" ::: Ptr Word32) -> IO VkResult Source #
vkAcquireNextImageKHR - Retrieve the index of the next available presentable image
Parameters
deviceis the device associated withswapchain.
swapchainis the non-retired swapchain from which an image is being acquired.timeoutspecifies how long the function waits, in nanoseconds, if no image is available.semaphoreisVK_NULL_HANDLEor a semaphore to signal.fenceisVK_NULL_HANDLEor a fence to signal.pImageIndexis a pointer to auint32_tthat is set to the index of the next image to use (i.e. an index into the array of images returned byvkGetSwapchainImagesKHR).
Description
Valid Usage
swapchainmust not be in the retired state
- If
semaphoreis notVK_NULL_HANDLEit must be unsignaled - If
semaphoreis notVK_NULL_HANDLEit must not have any uncompleted signal or wait operations pending - If
fenceis notVK_NULL_HANDLEit must be unsignaled and must not be associated with any other queue command that has not yet completed execution on that queue semaphoreandfencemust not both be equal toVK_NULL_HANDLE- If the number of currently acquired images is greater than the
difference between the number of images in
swapchainand the value ofVkSurfaceCapabilitiesKHR::minImageCountas returned by a call tovkGetPhysicalDeviceSurfaceCapabilities2KHRwith thesurfaceused to createswapchain,timeoutmust not beUINT64_MAX
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
swapchainmust be a validVkSwapchainKHRhandle- If
semaphoreis notVK_NULL_HANDLE,semaphoremust be a validVkSemaphorehandle - If
fenceis notVK_NULL_HANDLE,fencemust be a validVkFencehandle pImageIndexmust be a valid pointer to auint32_tvalue- If
semaphoreis a valid handle, it must have been created, allocated, or retrieved fromdevice - If
fenceis a valid handle, it must have been created, allocated, or retrieved fromdevice - Both of
device, andswapchainthat are valid handles must have been created, allocated, or retrieved from the sameVkInstance
Host Synchronization
- Host access to
swapchainmust be externally synchronized
- Host access to
semaphoremust be externally synchronized - Host access to
fencemust be externally synchronized
Return Codes
- Success
- -
VK_SUCCESSVK_TIMEOUT
VK_NOT_READY
VK_SUBOPTIMAL_KHR
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_DEVICE_LOST
VK_ERROR_OUT_OF_DATE_KHR
VK_ERROR_SURFACE_LOST_KHR
See Also
vkQueuePresentKHR :: ("queue" ::: VkQueue) -> ("pPresentInfo" ::: Ptr VkPresentInfoKHR) -> IO VkResult Source #
vkQueuePresentKHR - Queue an image for presentation
Parameters
queueis a queue that is capable of presentation to the target surface’s platform on the same device as the image’s swapchain.
pPresentInfois a pointer to an instance of theVkPresentInfoKHRstructure specifying the parameters of the presentation.
Description
Note
There is no requirement for an application to present images in the same order that they were acquired - applications can arbitrarily present any image that is currently acquired.
Valid Usage
- Each element of
pSwapchainsmember ofpPresentInfomust be a swapchain that is created for a surface for which presentation is supported fromqueueas determined using a call tovkGetPhysicalDeviceSurfaceSupportKHR
- If more than one member of
pSwapchainswas created from a display surface, all display surfaces referenced that refer to the same display must use the same display mode - When a semaphore unsignal operation defined by the elements of the
pWaitSemaphoresmember ofpPresentInfoexecutes onqueue, no other queue must be waiting on the same semaphore. - All elements of the
pWaitSemaphoresmember ofpPresentInfomust be semaphores that are signaled, or have semaphore signal operations previously submitted for execution.
Any writes to memory backing the images referenced by the
pImageIndices and pSwapchains members of pPresentInfo, that are
available before vkQueuePresentKHR is executed, are automatically made
visible to the read access performed by the presentation engine. This
automatic visibility operation for an image happens-after the semaphore
signal operation, and happens-before the presentation engine accesses
the image.
Queueing an image for presentation defines a set of queue operations, including waiting on the semaphores and submitting a presentation request to the presentation engine. However, the scope of this set of queue operations does not include the actual processing of the image by the presentation engine.
If vkQueuePresentKHR fails to enqueue the corresponding set of queue
operations, it may return VK_ERROR_OUT_OF_HOST_MEMORY or
VK_ERROR_OUT_OF_DEVICE_MEMORY. If it does, the implementation must
ensure that the state and contents of any resources or synchronization
primitives referenced is unaffected by the call or its failure.
If vkQueuePresentKHR fails in such a way that the implementation is
unable to make that guarantee, the implementation must return
VK_ERROR_DEVICE_LOST.
However, if the presentation request is rejected by the presentation
engine with an error VK_ERROR_OUT_OF_DATE_KHR or
VK_ERROR_SURFACE_LOST_KHR, the set of queue operations are still
considered to be enqueued and thus any semaphore to be waited on gets
unsignaled when the corresponding queue operation is complete.
Valid Usage (Implicit)
queuemust be a validVkQueuehandle
pPresentInfomust be a valid pointer to a validVkPresentInfoKHRstructure
Host Synchronization
- Host access to
queuemust be externally synchronized
- Host access to
pPresentInfo.pWaitSemaphores[] must be externally synchronized - Host access to
pPresentInfo.pSwapchains[] must be externally synchronized
Command Properties
+-----------------+-----------------+-----------------+-----------------+ | <#VkCommandBuff | <#vkCmdBeginRen | <#VkQueueFlagBi | <#synchronizati | | erLevel Command | derPass Render | ts Supported Qu | on-pipeline-sta | | Buffer Levels> | Pass Scope> | eue Types> | ges-types Pipel | | | | | ine Type> | +=================+=================+=================+=================+ | - | - | Any | - | +-----------------+-----------------+-----------------+-----------------+
Return Codes
- Success
- -
VK_SUCCESSVK_SUBOPTIMAL_KHR
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_DEVICE_LOST
VK_ERROR_OUT_OF_DATE_KHR
VK_ERROR_SURFACE_LOST_KHR
See Also
vkGetDeviceGroupPresentCapabilitiesKHR :: ("device" ::: VkDevice) -> ("pDeviceGroupPresentCapabilities" ::: Ptr VkDeviceGroupPresentCapabilitiesKHR) -> IO VkResult Source #
vkGetDeviceGroupPresentCapabilitiesKHR - Query present capabilities from other physical devices
Parameters
deviceis the logical device.
pDeviceGroupPresentCapabilitiesis a pointer to a structure of typeVkDeviceGroupPresentCapabilitiesKHRthat is filled with the logical device’s capabilities.
Description
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
pDeviceGroupPresentCapabilitiesmust be a valid pointer to aVkDeviceGroupPresentCapabilitiesKHRstructure
Return Codes
- Success
- -
VK_SUCCESS
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
See Also
vkGetDeviceGroupSurfacePresentModesKHR :: ("device" ::: VkDevice) -> ("surface" ::: VkSurfaceKHR) -> ("pModes" ::: Ptr VkDeviceGroupPresentModeFlagsKHR) -> IO VkResult Source #
vkGetDeviceGroupSurfacePresentModesKHR - Query present capabilities for a surface
Parameters
deviceis the logical device.
surfaceis the surface.pModesis a pointer to a value of typeVkDeviceGroupPresentModeFlagsKHRthat is filled with the supported device group present modes for the surface.
Description
The modes returned by this command are not invariant, and may change
in response to the surface being moved, resized, or occluded. These
modes must be a subset of the modes returned by
vkGetDeviceGroupPresentCapabilitiesKHR.
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
surfacemust be a validVkSurfaceKHRhandlepModesmust be a valid pointer to aVkDeviceGroupPresentModeFlagsKHRvalue- Both of
device, andsurfacemust have been created, allocated, or retrieved from the sameVkInstance
Host Synchronization
- Host access to
surfacemust be externally synchronized
Return Codes
- Success
- -
VK_SUCCESS
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_SURFACE_LOST_KHR
See Also
vkAcquireNextImage2KHR :: ("device" ::: VkDevice) -> ("pAcquireInfo" ::: Ptr VkAcquireNextImageInfoKHR) -> ("pImageIndex" ::: Ptr Word32) -> IO VkResult Source #
vkAcquireNextImage2KHR - Retrieve the index of the next available presentable image
Parameters
deviceis the device associated withswapchain.
pAcquireInfois a pointer to a structure of typeVkAcquireNextImageInfoKHRcontaining parameters of the acquire.pImageIndexis a pointer to auint32_tthat is set to the index of the next image to use.
Description
Valid Usage
- If the number of currently acquired images is greater than the
difference between the number of images in the
swapchainmember ofpAcquireInfoand the value ofVkSurfaceCapabilitiesKHR::minImageCountas returned by a call tovkGetPhysicalDeviceSurfaceCapabilities2KHRwith thesurfaceused to createswapchain, thetimeoutmember ofpAcquireInfomust not beUINT64_MAX
Valid Usage (Implicit)
devicemust be a validVkDevicehandle
pAcquireInfomust be a valid pointer to a validVkAcquireNextImageInfoKHRstructurepImageIndexmust be a valid pointer to auint32_tvalue
Return Codes
- Success
- -
VK_SUCCESSVK_TIMEOUT
VK_NOT_READY
VK_SUBOPTIMAL_KHR
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_DEVICE_LOST
VK_ERROR_OUT_OF_DATE_KHR
VK_ERROR_SURFACE_LOST_KHR
See Also
vkGetPhysicalDevicePresentRectanglesKHR :: ("physicalDevice" ::: VkPhysicalDevice) -> ("surface" ::: VkSurfaceKHR) -> ("pRectCount" ::: Ptr Word32) -> ("pRects" ::: Ptr VkRect2D) -> IO VkResult Source #
vkGetPhysicalDevicePresentRectanglesKHR - Query present rectangles for a surface on a physical device
Parameters
physicalDeviceis the physical device.
surfaceis the surface.pRectCountis a pointer to an integer related to the number of rectangles available or queried, as described below.pRectsis eitherNULLor a pointer to an array ofVkRect2Dstructures.
Description
If pRects is NULL, then the number of rectangles used when
presenting the given surface is returned in pRectCount. Otherwise,
pRectCount must point to a variable set by the user to the number of
elements in the pRects array, and on return the variable is
overwritten with the number of structures actually written to pRects.
If the value of pRectCount is less than the number of rectangles, at
most pRectCount structures will be written. If pRectCount is smaller
than the number of rectangles used for the given surface,
VK_INCOMPLETE will be returned instead of VK_SUCCESS to indicate
that not all the available values were returned.
The values returned by this command are not invariant, and may change in response to the surface being moved, resized, or occluded.
The rectangles returned by this command must not overlap.
Valid Usage (Implicit)
physicalDevicemust be a validVkPhysicalDevicehandle
surfacemust be a validVkSurfaceKHRhandlepRectCountmust be a valid pointer to auint32_tvalue- If the value referenced by
pRectCountis not0, andpRectsis notNULL,pRectsmust be a valid pointer to an array ofpRectCountVkRect2Dstructures - Both of
physicalDevice, andsurfacemust have been created, allocated, or retrieved from the sameVkInstance
Host Synchronization
- Host access to
surfacemust be externally synchronized
Return Codes
- Success
- -
VK_SUCCESSVK_INCOMPLETE
- Failure
- -
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORY
See Also
data VkSwapchainCreateInfoKHR Source #
VkSwapchainCreateInfoKHR - Structure specifying parameters of a newly created swapchain object
Description
Note
On some platforms, it is normal that maxImageExtent may become (0,
0), for example when the window is minimized. In such a case, it is not
possible to create a swapchain due to the Valid Usage requirements.
imageArrayLayersis the number of views in a multiview/stereo surface. For non-stereoscopic-3D applications, this value is 1.imageUsageis a bitmask ofVkImageUsageFlagBitsdescribing the intended usage of the (acquired) swapchain images.imageSharingModeis the sharing mode used for the image(s) of the swapchain.queueFamilyIndexCountis the number of queue families having access to the image(s) of the swapchain whenimageSharingModeisVK_SHARING_MODE_CONCURRENT.pQueueFamilyIndicesis an array of queue family indices having access to the images(s) of the swapchain whenimageSharingModeisVK_SHARING_MODE_CONCURRENT.preTransformis aVkSurfaceTransformFlagBitsKHRvalue describing the transform, relative to the presentation engine’s natural orientation, applied to the image content prior to presentation. If it does not match thecurrentTransformvalue returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHR, the presentation engine will transform the image content as part of the presentation operation.compositeAlphais aVkCompositeAlphaFlagBitsKHRvalue indicating the alpha compositing mode to use when this surface is composited together with other surfaces on certain window systems.presentModeis the presentation mode the swapchain will use. A swapchain’s present mode determines how incoming present requests will be processed and queued internally.clippedspecifies whether the Vulkan implementation is allowed to discard rendering operations that affect regions of the surface that are not visible.- If set to
VK_TRUE, the presentable images associated with the swapchain may not own all of their pixels. Pixels in the presentable images that correspond to regions of the target surface obscured by another window on the desktop, or subject to some other clipping mechanism will have undefined content when read back. Pixel shaders may not execute for these pixels, and thus any side effects they would have had will not occur.VK_TRUEvalue does not guarantee any clipping will occur, but allows more optimal presentation methods to be used on some platforms. - If set to
VK_FALSE, presentable images associated with the swapchain will own all of the pixels they contain.
- If set to
Note
Applications should set this value to VK_TRUE if they do not expect
to read back the content of presentable images before presenting them or
after reacquiring them, and if their pixel shaders do not have any side
effects that require them to run for all pixels in the presentable
image.
oldSwapchainisVK_NULL_HANDLE, or the existing non-retired swapchain currently associated withsurface. Providing a validoldSwapchainmay aid in the resource reuse, and also allows the application to still present any images that are already acquired from it.
Upon calling vkCreateSwapchainKHR with an oldSwapchain that is not
VK_NULL_HANDLE, oldSwapchain is
retired — even if creation of the new swapchain fails. The new swapchain
is created in the non-retired state whether or not oldSwapchain is
VK_NULL_HANDLE.
Upon calling vkCreateSwapchainKHR with an oldSwapchain that is not
VK_NULL_HANDLE, any images from
oldSwapchain that are not acquired by the application may be freed
by the implementation, which may occur even if creation of the new
swapchain fails. The application can destroy oldSwapchain to free
all memory associated with oldSwapchain.
Note
Multiple retired swapchains can be associated with the same
VkSurfaceKHR through multiple uses of oldSwapchain that outnumber
calls to vkDestroySwapchainKHR.
After oldSwapchain is retired, the application can pass to
vkQueuePresentKHR any images it had already acquired from
oldSwapchain. E.g., an application may present an image from the old
swapchain before an image from the new swapchain is ready to be
presented. As usual, vkQueuePresentKHR may fail if oldSwapchain
has entered a state that causes VK_ERROR_OUT_OF_DATE_KHR to be
returned.
The application can continue to use a shared presentable image
obtained from oldSwapchain until a presentable image is acquired from
the new swapchain, as long as it has not entered a state that causes it
to return VK_ERROR_OUT_OF_DATE_KHR.
Valid Usage
surfacemust be a surface that is supported by the device as determined usingvkGetPhysicalDeviceSurfaceSupportKHR
minImageCountmust be greater than or equal to the value returned in theminImageCountmember of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRfor the surfaceminImageCountmust be less than or equal to the value returned in themaxImageCountmember of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRfor the surface if the returnedmaxImageCountis not zerominImageCountmust be1ifpresentModeis eitherVK_PRESENT_MODE_SHARED_DEMAND_REFRESH_KHRorVK_PRESENT_MODE_SHARED_CONTINUOUS_REFRESH_KHRimageFormatandimageColorSpacemust match theformatandcolorSpacemembers, respectively, of one of theVkSurfaceFormatKHRstructures returned byvkGetPhysicalDeviceSurfaceFormatsKHRfor the surfaceimageExtentmust be betweenminImageExtentandmaxImageExtent, inclusive, whereminImageExtentandmaxImageExtentare members of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRfor the surfaceimageExtentmemberswidthandheightmust both be non-zeroimageArrayLayersmust be greater than0and less than or equal to themaxImageArrayLayersmember of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRfor the surface- If
presentModeisVK_PRESENT_MODE_IMMEDIATE_KHR,VK_PRESENT_MODE_MAILBOX_KHR,VK_PRESENT_MODE_FIFO_KHRorVK_PRESENT_MODE_FIFO_RELAXED_KHR,imageUsagemust be a subset of the supported usage flags present in thesupportedUsageFlagsmember of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRforsurface - If
presentModeisVK_PRESENT_MODE_SHARED_DEMAND_REFRESH_KHRorVK_PRESENT_MODE_SHARED_CONTINUOUS_REFRESH_KHR,imageUsagemust be a subset of the supported usage flags present in thesharedPresentSupportedUsageFlagsmember of theVkSharedPresentSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilities2KHRforsurface - If
imageSharingModeisVK_SHARING_MODE_CONCURRENT,pQueueFamilyIndicesmust be a valid pointer to an array ofqueueFamilyIndexCountuint32_tvalues - If
imageSharingModeisVK_SHARING_MODE_CONCURRENT,queueFamilyIndexCountmust be greater than1 - If
imageSharingModeisVK_SHARING_MODE_CONCURRENT, each element ofpQueueFamilyIndicesmust be unique and must be less thanpQueueFamilyPropertyCountreturned by eithervkGetPhysicalDeviceQueueFamilyPropertiesorvkGetPhysicalDeviceQueueFamilyProperties2for thephysicalDevicethat was used to createdevice preTransformmust be one of the bits present in thesupportedTransformsmember of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRfor the surfacecompositeAlphamust be one of the bits present in thesupportedCompositeAlphamember of theVkSurfaceCapabilitiesKHRstructure returned byvkGetPhysicalDeviceSurfaceCapabilitiesKHRfor the surfacepresentModemust be one of theVkPresentModeKHRvalues returned byvkGetPhysicalDeviceSurfacePresentModesKHRfor the surface- If the logical device was created with
VkDeviceGroupDeviceCreateInfo::physicalDeviceCountequal to 1,flagsmust not containVK_SWAPCHAIN_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT_KHR oldSwapchainmust not be in the retired stateimageFormat,imageUsage,imageExtent, andimageArrayLayersmust be supported forVK_IMAGE_TYPE_2DVK_IMAGE_TILING_OPTIMALimages as reported byvkGetPhysicalDeviceImageFormatProperties.
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_SWAPCHAIN_CREATE_INFO_KHR
- Each
pNextmember of any structure (including this one) in thepNextchain must be eitherNULLor a pointer to a valid instance ofVkDeviceGroupSwapchainCreateInfoKHRorVkSwapchainCounterCreateInfoEXT - Each
sTypemember in thepNextchain must be unique flagsmust be a valid combination ofVkSwapchainCreateFlagBitsKHRvaluessurfacemust be a validVkSurfaceKHRhandleimageFormatmust be a validVkFormatvalueimageColorSpacemust be a validVkColorSpaceKHRvalueimageUsagemust be a valid combination ofVkImageUsageFlagBitsvaluesimageUsagemust not be0imageSharingModemust be a validVkSharingModevaluepreTransformmust be a validVkSurfaceTransformFlagBitsKHRvaluecompositeAlphamust be a validVkCompositeAlphaFlagBitsKHRvaluepresentModemust be a validVkPresentModeKHRvalue- If
oldSwapchainis notVK_NULL_HANDLE,oldSwapchainmust be a validVkSwapchainKHRhandle - If
oldSwapchainis a valid handle, it must have been created, allocated, or retrieved fromsurface - Both of
oldSwapchain, andsurfacethat are valid handles must have been created, allocated, or retrieved from the sameVkInstance
See Also
VkBool32, VkColorSpaceKHR,
VkCompositeAlphaFlagBitsKHR,
VkExtent2D,
VkFormat,
VkImageUsageFlags,
VkPresentModeKHR,
VkSharingMode,
VkStructureType,
VkSurfaceKHR,
VkSurfaceTransformFlagBitsKHR,
VkSwapchainCreateFlagsKHR, VkSwapchainKHR,
vkCreateSharedSwapchainsKHR,
vkCreateSwapchainKHR
Constructors
| VkSwapchainCreateInfoKHR | |
Fields
| |
data VkPresentInfoKHR Source #
VkPresentInfoKHR - Structure describing parameters of a queue presentation
Description
Before an application can present an image, the image’s layout must
be transitioned to the VK_IMAGE_LAYOUT_PRESENT_SRC_KHR layout, or for
a shared presentable image the VK_IMAGE_LAYOUT_SHARED_PRESENT_KHR
layout.
Note
When transitioning the image to VK_IMAGE_LAYOUT_SHARED_PRESENT_KHR or
VK_IMAGE_LAYOUT_PRESENT_SRC_KHR, there is no need to delay subsequent
processing, or perform any visibility operations (as vkQueuePresentKHR
performs automatic visibility operations). To achieve this, the
dstAccessMask member of the
VkImageMemoryBarrier
should be set to 0, and the dstStageMask parameter should be set
to VK_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT.
Valid Usage
- Each element of
pImageIndicesmust be the index of a presentable image acquired from the swapchain specified by the corresponding element of thepSwapchainsarray, and the presented image subresource must be in theVK_IMAGE_LAYOUT_PRESENT_SRC_KHRorVK_IMAGE_LAYOUT_SHARED_PRESENT_KHRlayout at the time the operation is executed on aVkDevice
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_PRESENT_INFO_KHR
- Each
pNextmember of any structure (including this one) in thepNextchain must be eitherNULLor a pointer to a valid instance ofVkDeviceGroupPresentInfoKHR,VkDisplayPresentInfoKHR,VkPresentRegionsKHR, orVkPresentTimesInfoGOOGLE - Each
sTypemember in thepNextchain must be unique - If
waitSemaphoreCountis not0,pWaitSemaphoresmust be a valid pointer to an array ofwaitSemaphoreCountvalidVkSemaphorehandles pSwapchainsmust be a valid pointer to an array ofswapchainCountvalidVkSwapchainKHRhandlespImageIndicesmust be a valid pointer to an array ofswapchainCountuint32_tvalues- If
pResultsis notNULL,pResultsmust be a valid pointer to an array ofswapchainCountVkResultvalues swapchainCountmust be greater than0- Both of the elements of
pSwapchains, and the elements ofpWaitSemaphoresthat are valid handles must have been created, allocated, or retrieved from the sameVkInstance
See Also
VkResult,
VkSemaphore,
VkStructureType, VkSwapchainKHR,
vkQueuePresentKHR
Constructors
| VkPresentInfoKHR | |
Fields
| |
Instances
data VkDeviceGroupPresentCapabilitiesKHR Source #
VkDeviceGroupPresentCapabilitiesKHR - Present capabilities from other physical devices
Description
modes always has VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR set.
The present mode flags are also used when presenting an image, in
VkDeviceGroupPresentInfoKHR::mode.
If a device group only includes a single physical device, then modes
must equal VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR.
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_DEVICE_GROUP_PRESENT_CAPABILITIES_KHR
pNextmust beNULL
See Also
VkDeviceGroupPresentModeFlagsKHR,
VkStructureType,
vkGetDeviceGroupPresentCapabilitiesKHR
Constructors
| VkDeviceGroupPresentCapabilitiesKHR | |
Fields
| |
data VkImageSwapchainCreateInfoKHR Source #
VkImageSwapchainCreateInfoKHR - Specify that an image will be bound to swapchain memory
Description
Valid Usage
- If
swapchainis notVK_NULL_HANDLE, the fields ofVkImageCreateInfomust match the implied image creation parameters of the swapchain
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_IMAGE_SWAPCHAIN_CREATE_INFO_KHR
- If
swapchainis notVK_NULL_HANDLE,swapchainmust be a validVkSwapchainKHRhandle
See Also
Constructors
| VkImageSwapchainCreateInfoKHR | |
Fields
| |
data VkBindImageMemorySwapchainInfoKHR Source #
VkBindImageMemorySwapchainInfoKHR - Structure specifying swapchain image memory to bind to
Description
If swapchain is not NULL, the swapchain and imageIndex are used
to determine the memory that the image is bound to, instead of memory
and memoryOffset.
Memory can be bound to a swapchain and use the pDeviceIndices or
pSplitInstanceBindRegions members of
VkBindImageMemoryDeviceGroupInfo.
Valid Usage
imageIndexmust be less than the number of images inswapchain
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_BIND_IMAGE_MEMORY_SWAPCHAIN_INFO_KHR
swapchainmust be a validVkSwapchainKHRhandle
Host Synchronization
- Host access to
swapchainmust be externally synchronized
See Also
Constructors
| VkBindImageMemorySwapchainInfoKHR | |
Fields
| |
data VkAcquireNextImageInfoKHR Source #
VkAcquireNextImageInfoKHR - Structure specifying parameters of the acquire
Description
If vkAcquireNextImageKHR is used, the device mask is considered to
include all physical devices in the logical device.
Note
vkAcquireNextImage2KHR signals at most one semaphore, even if the
application requests waiting for multiple physical devices to be ready
via the deviceMask. However, only a single physical device can wait
on that semaphore, since the semaphore becomes unsignaled when the wait
succeeds. For other physical devices to wait for the image to be ready,
it is necessary for the application to submit semaphore signal
operation(s) to that first physical device to signal additional
semaphore(s) after the wait succeeds, which the other physical device(s)
can wait upon.
Valid Usage
swapchainmust not be in the retired state
- If
semaphoreis notVK_NULL_HANDLEit must be unsignaled - If
semaphoreis notVK_NULL_HANDLEit must not have any uncompleted signal or wait operations pending - If
fenceis notVK_NULL_HANDLEit must be unsignaled and must not be associated with any other queue command that has not yet completed execution on that queue semaphoreandfencemust not both be equal toVK_NULL_HANDLEdeviceMaskmust be a valid device maskdeviceMaskmust not be zerosemaphoreandfencemust not both be equal toVK_NULL_HANDLE.
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_ACQUIRE_NEXT_IMAGE_INFO_KHR
pNextmust beNULLswapchainmust be a validVkSwapchainKHRhandle- If
semaphoreis notVK_NULL_HANDLE,semaphoremust be a validVkSemaphorehandle - If
fenceis notVK_NULL_HANDLE,fencemust be a validVkFencehandle - Each of
fence,semaphore, andswapchainthat are valid handles must have been created, allocated, or retrieved from the sameVkInstance
Host Synchronization
- Host access to
swapchainmust be externally synchronized
- Host access to
semaphoremust be externally synchronized - Host access to
fencemust be externally synchronized
See Also
VkFence,
VkSemaphore,
VkStructureType, VkSwapchainKHR,
vkAcquireNextImage2KHR
Constructors
| VkAcquireNextImageInfoKHR | |
Fields
| |
data VkDeviceGroupPresentInfoKHR Source #
VkDeviceGroupPresentInfoKHR - Mode and mask controlling which physical devices' images are presented
Description
If mode is VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR, then each
element of pDeviceMasks selects which instance of the swapchain image
is presented. Each element of pDeviceMasks must have exactly one bit
set, and the corresponding physical device must have a presentation
engine as reported by VkDeviceGroupPresentCapabilitiesKHR.
If mode is VK_DEVICE_GROUP_PRESENT_MODE_REMOTE_BIT_KHR, then each
element of pDeviceMasks selects which instance of the swapchain image
is presented. Each element of pDeviceMasks must have exactly one bit
set, and some physical device in the logical device must include that
bit in its VkDeviceGroupPresentCapabilitiesKHR::presentMask.
If mode is VK_DEVICE_GROUP_PRESENT_MODE_SUM_BIT_KHR, then each
element of pDeviceMasks selects which instances of the swapchain image
are component-wise summed and the sum of those images is presented. If
the sum in any component is outside the representable range, the value
of that component is undefined. Each element of pDeviceMasks must
have a value for which all set bits are set in one of the elements of
VkDeviceGroupPresentCapabilitiesKHR::presentMask.
If mode is VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHR,
then each element of pDeviceMasks selects which instance(s) of the
swapchain images are presented. For each bit set in each element of
pDeviceMasks, the corresponding physical device must have a
presentation engine as reported by
VkDeviceGroupPresentCapabilitiesKHR.
If VkDeviceGroupPresentInfoKHR is not provided or swapchainCount is
zero then the masks are considered to be 1. If
VkDeviceGroupPresentInfoKHR is not provided, mode is considered to
be VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR.
Valid Usage
swapchainCountmust equal0orVkPresentInfoKHR::swapchainCount
- If
modeisVK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR, then each element ofpDeviceMasksmust have exactly one bit set, and the corresponding element ofVkDeviceGroupPresentCapabilitiesKHR::presentMaskmust be non-zero - If
modeisVK_DEVICE_GROUP_PRESENT_MODE_REMOTE_BIT_KHR, then each element ofpDeviceMasksmust have exactly one bit set, and some physical device in the logical device must include that bit in itsVkDeviceGroupPresentCapabilitiesKHR::presentMask. - If
modeisVK_DEVICE_GROUP_PRESENT_MODE_SUM_BIT_KHR, then each element ofpDeviceMasksmust have a value for which all set bits are set in one of the elements ofVkDeviceGroupPresentCapabilitiesKHR::presentMask - If
modeisVK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHR, then for each bit set in each element ofpDeviceMasks, the corresponding element ofVkDeviceGroupPresentCapabilitiesKHR::presentMaskmust be non-zero - The value of each element of
pDeviceMasksmust be equal to the device mask passed inVkAcquireNextImageInfoKHR::deviceMaskwhen the image index was last acquired modemust have exactly one bit set, and that bit must have been included inVkDeviceGroupSwapchainCreateInfoKHR::modes
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_DEVICE_GROUP_PRESENT_INFO_KHR
- If
swapchainCountis not0,pDeviceMasksmust be a valid pointer to an array ofswapchainCountuint32_tvalues modemust be a validVkDeviceGroupPresentModeFlagBitsKHRvalue
See Also
Constructors
| VkDeviceGroupPresentInfoKHR | |
Fields
| |
data VkDeviceGroupSwapchainCreateInfoKHR Source #
VkDeviceGroupSwapchainCreateInfoKHR - Structure specifying parameters of a newly created swapchain object
Description
If this structure is not present, modes is considered to be
VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR.
Valid Usage (Implicit)
sTypemust beVK_STRUCTURE_TYPE_DEVICE_GROUP_SWAPCHAIN_CREATE_INFO_KHR
modesmust be a valid combination ofVkDeviceGroupPresentModeFlagBitsKHRvaluesmodesmust not be0
See Also
Constructors
| VkDeviceGroupSwapchainCreateInfoKHR | |
Fields
| |
type VkSwapchainCreateFlagsKHR = VkSwapchainCreateFlagBitsKHR Source #
VkSwapchainCreateFlagsKHR - Bitmask of VkSwapchainCreateFlagBitsKHR
Description
VkSwapchainCreateFlagsKHR is a bitmask type for setting a mask of zero
or more VkSwapchainCreateFlagBitsKHR.
See Also
type VkDeviceGroupPresentModeFlagsKHR = VkDeviceGroupPresentModeFlagBitsKHR Source #
VkDeviceGroupPresentModeFlagsKHR - Bitmask of VkDeviceGroupPresentModeFlagBitsKHR
Description
VkDeviceGroupPresentModeFlagsKHR is a bitmask type for setting a mask
of zero or more VkDeviceGroupPresentModeFlagBitsKHR.
See Also
VkDeviceGroupPresentCapabilitiesKHR,
VkDeviceGroupPresentModeFlagBitsKHR,
VkDeviceGroupSwapchainCreateInfoKHR,
vkGetDeviceGroupSurfacePresentModesKHR