|
Monado OpenXR Runtime
|
Native compositor swapchain: extends xrt_swapchain with a process-local id and (usually) an xrt_allocation_collection that owns the GPU images. More...
#include <xrt/xrt_compositor.h>


Data Fields | |
| struct xrt_swapchain | base |
| Base. | |
| xrt_limited_unique_id_t | limited_unique_id |
| Unique id for the swapchain, only unique for the current process, is not synchronized between service and any apps via the IPC layer. | |
| struct xrt_allocation_collection * | xac |
| Allocation collection for this swapchain's images. | |
Data Fields inherited from xrt_swapchain | |
| struct xrt_reference | reference |
| Reference helper. | |
| uint32_t | image_count |
| Number of images. | |
| void(* | destroy )(struct xrt_swapchain *xsc) |
| dec_image_use must have been called as often as inc_image_use. | |
| xrt_result_t(* | acquire_image )(struct xrt_swapchain *xsc, uint32_t *out_index) |
| Obtain the index of the next image to use, without blocking on being able to write to it. | |
| xrt_result_t(* | inc_image_use )(struct xrt_swapchain *xsc, uint32_t index) |
| Increments the use counter of a swapchain image. | |
| xrt_result_t(* | dec_image_use )(struct xrt_swapchain *xsc, uint32_t index) |
| Decrements the use counter of a swapchain image. | |
| xrt_result_t(* | wait_image )(struct xrt_swapchain *xsc, int64_t timeout_ns, uint32_t index) |
Wait until image index is available for exclusive use, or until timeout_ns expires. | |
| xrt_result_t(* | barrier_image )(struct xrt_swapchain *xsc, enum xrt_barrier_direction direction, uint32_t index) |
| Do any barrier transitions to and from the application. | |
| xrt_result_t(* | release_image )(struct xrt_swapchain *xsc, uint32_t index) |
| See xrReleaseSwapchainImage, state tracker needs to track index. | |
Related Symbols | |
(Note that these are not member symbols.) | |
| static void | xrt_swapchain_native_reference (struct xrt_swapchain_native **dst, struct xrt_swapchain_native *src) |
| Update the reference counts on swapchain(s). | |
Related Symbols inherited from xrt_swapchain | |
| static XRT_NONNULL_FIRST void | xrt_swapchain_reference (struct xrt_swapchain **dst, struct xrt_swapchain *src) |
| Update the reference counts on swapchain(s). | |
Additional Inherited Members | |
Static Public Member Functions inherited from xrt_swapchain | |
| static XRT_NONNULL_ALL xrt_result_t | xrt_swapchain_acquire_image (struct xrt_swapchain *xsc, uint32_t *out_index) |
| Obtain the index of the next image to use, without blocking on being able to write to it. | |
| static XRT_NONNULL_ALL xrt_result_t | xrt_swapchain_inc_image_use (struct xrt_swapchain *xsc, uint32_t index) |
| Increments the use counter of a swapchain image. | |
| static XRT_NONNULL_ALL xrt_result_t | xrt_swapchain_dec_image_use (struct xrt_swapchain *xsc, uint32_t index) |
| Decrements the use counter of a swapchain image. | |
| static XRT_NONNULL_ALL xrt_result_t | xrt_swapchain_wait_image (struct xrt_swapchain *xsc, int64_t timeout_ns, uint32_t index) |
Wait until image index is available for exclusive use, or until timeout_ns expires. | |
| static XRT_NONNULL_ALL xrt_result_t | xrt_swapchain_barrier_image (struct xrt_swapchain *xsc, enum xrt_barrier_direction direction, uint32_t index) |
| Do any barrier transitions to and from the application. | |
| static XRT_NONNULL_ALL xrt_result_t | xrt_swapchain_release_image (struct xrt_swapchain *xsc, uint32_t index) |
| See xrReleaseSwapchainImage, state tracker needs to track index. | |
Native compositor swapchain: extends xrt_swapchain with a process-local id and (usually) an xrt_allocation_collection that owns the GPU images.
Per-image native handles are not stored on this struct; clients obtain them from the xrt_allocation_collection see the struct for more details. Often XRT_ALLOCATION_TYPE_NATIVE_IMAGE is used to import the images into other APIS, or directly use the XRT_ALLOCATION_TYPE_VULKAN_IMAGE type.
| struct xrt_swapchain xrt_swapchain_native::base |
| xrt_limited_unique_id_t xrt_swapchain_native::limited_unique_id |
Unique id for the swapchain, only unique for the current process, is not synchronized between service and any apps via the IPC layer.
| struct xrt_allocation_collection* xrt_swapchain_native::xac |
Allocation collection for this swapchain's images.
Implementations MUST set this to a non-NULL collection for swapchains created with the xrt_compositor::create_swapchain function.
This field MUST only be NULL for imported swapchains where the compositor implementation MAY not attach a client-side allocation collection.
Referenced by cleanup_post_create_vulkan_setup(), client_gl_eglimage_swapchain_create(), client_gl_memobj_swapchain_create(), client_vk_swapchain_create(), comp_swapchain_create_init(), comp_swapchain_import_init(), and get_and_store_vk_images().