Monado OpenXR Runtime
Loading...
Searching...
No Matches
comp_renderer Struct Reference

Holds associated vulkan objects and state to render with a distortion. More...

Collaboration diagram for comp_renderer:

Public Member Functions

struct comp_renderercomp_renderer_create (struct comp_compositor *c, VkExtent2D scratch_extent)
 Called by the main compositor code to create the renderer.
 
void comp_renderer_destroy (struct comp_renderer **ptr_r)
 Clean up and free the renderer.
 
XRT_CHECK_RESULT xrt_result_t comp_renderer_draw (struct comp_renderer *r)
 Render frame.
 

Data Fields

Durable members

These don't require the images to be created and don't depend on it.

struct comp_compositorc
 The compositor we were created by.
 
struct comp_settingssettings
 
struct comp_mirror_to_debug_gui mirror_to_debug_gui
 
Image-dependent members
int32_t acquired_buffer
 Index of the current buffer/image.
 
int32_t fenced_buffer
 Which buffer was last submitted and has a fence pending.
 
struct render_gfx_render_pass target_render_pass
 The render pass used to render to the target, it depends on the target's format so will be recreated each time the target changes.
 
struct render_gfx_target_resourcesrtr_array
 Array of "rendering" target resources equal in size to the number of comp_target images.
 
VkFence * fences
 Array of fences equal in size to the number of comp_target images.
 
uint32_t buffer_count
 The number of renderings/fences we've created: set from comp_target when we use that data.
 
bool shared_present_semaphore_wait_once
 Only relevant when using present modes from VK_KHR_shared_presentable_image, tracks whether we have waited on the shared present semaphore at least once, subsequents present waits are redundant and can be skipped.
 

Detailed Description

Holds associated vulkan objects and state to render with a distortion.

Field Documentation

◆ acquired_buffer

int32_t comp_renderer::acquired_buffer

Index of the current buffer/image.

Referenced by comp_renderer_draw(), dispatch_compute(), and renderer_init().

◆ buffer_count

uint32_t comp_renderer::buffer_count

The number of renderings/fences we've created: set from comp_target when we use that data.

Referenced by renderer_create_renderings_and_fences().

◆ c

◆ fenced_buffer

int32_t comp_renderer::fenced_buffer

Which buffer was last submitted and has a fence pending.

Referenced by renderer_init().

◆ fences

VkFence* comp_renderer::fences

Array of fences equal in size to the number of comp_target images.

Referenced by renderer_create_renderings_and_fences().

◆ rtr_array

struct render_gfx_target_resources* comp_renderer::rtr_array

Array of "rendering" target resources equal in size to the number of comp_target images.

Each target resources holds all of the resources needed to render to that target and its views.

Referenced by renderer_create_renderings_and_fences(), and renderer_init().

◆ shared_present_semaphore_wait_once

bool comp_renderer::shared_present_semaphore_wait_once

Only relevant when using present modes from VK_KHR_shared_presentable_image, tracks whether we have waited on the shared present semaphore at least once, subsequents present waits are redundant and can be skipped.

Referenced by requires_present_acquire_wait().

◆ target_render_pass

struct render_gfx_render_pass comp_renderer::target_render_pass

The render pass used to render to the target, it depends on the target's format so will be recreated each time the target changes.

Referenced by renderer_build_rendering_target_resources(), and renderer_create_renderings_and_fences().


The documentation for this struct was generated from the following files: