Monado OpenXR Runtime
|
Compositor (compute shader) rendering code. More...
#include "util/comp_layer_accum.h"
#include "xrt/xrt_compositor.h"
#include "os/os_time.h"
#include "math/m_api.h"
#include "math/m_mathinclude.h"
#include "util/u_misc.h"
#include "util/u_trace_marker.h"
#include "vk/vk_helpers.h"
#include "render/render_interface.h"
#include "util/comp_render.h"
#include "util/comp_render_helpers.h"
#include "util/comp_base.h"
Functions | |
static const struct comp_swapchain_image * | get_layer_image (const struct comp_layer *layer, uint32_t swapchain_index, uint32_t image_index) |
static const struct comp_swapchain_image * | get_layer_depth_image (const struct comp_layer *layer, uint32_t swapchain_index, uint32_t image_index) |
static void | do_cs_cylinder_layer (const struct comp_layer *layer, const struct xrt_matrix_4x4 *eye_view_mat, const struct xrt_matrix_4x4 *world_view_mat, uint32_t view_index, uint32_t cur_layer, uint32_t cur_image, VkSampler clamp_to_edge, VkSampler clamp_to_border_black, VkSampler src_samplers[RENDER_MAX_IMAGES_SIZE], VkImageView src_image_views[RENDER_MAX_IMAGES_SIZE], struct render_compute_layer_ubo_data *ubo_data, uint32_t *out_cur_image) |
Data setup for a cylinder layer. More... | |
static void | do_cs_equirect2_layer (const struct comp_layer *layer, const struct xrt_matrix_4x4 *eye_view_mat, const struct xrt_matrix_4x4 *world_view_mat, uint32_t view_index, uint32_t cur_layer, uint32_t cur_image, VkSampler clamp_to_edge, VkSampler clamp_to_border_black, VkSampler src_samplers[RENDER_MAX_IMAGES_SIZE], VkImageView src_image_views[RENDER_MAX_IMAGES_SIZE], struct render_compute_layer_ubo_data *ubo_data, uint32_t *out_cur_image) |
Data setup for an "equirect2" layer. More... | |
static void | do_cs_projection_layer (const struct comp_layer *layer, const struct xrt_pose *world_pose, uint32_t view_index, uint32_t cur_layer, uint32_t cur_image, VkSampler clamp_to_edge, VkSampler clamp_to_border_black, VkSampler src_samplers[RENDER_MAX_IMAGES_SIZE], VkImageView src_image_views[RENDER_MAX_IMAGES_SIZE], struct render_compute_layer_ubo_data *ubo_data, bool do_timewarp, uint32_t *out_cur_image) |
Data setup for a projection layer. More... | |
static void | do_cs_quad_layer (const struct comp_layer *layer, const struct xrt_matrix_4x4 *eye_view_mat, const struct xrt_matrix_4x4 *world_view_mat, uint32_t view_index, uint32_t cur_layer, uint32_t cur_image, VkSampler clamp_to_edge, VkSampler clamp_to_border_black, VkSampler src_samplers[RENDER_MAX_IMAGES_SIZE], VkImageView src_image_views[RENDER_MAX_IMAGES_SIZE], struct render_compute_layer_ubo_data *ubo_data, uint32_t *out_cur_image) |
Data setup for a quad layer. More... | |
static void | crc_clear_output (struct render_compute *render, const struct comp_render_dispatch_data *d) |
static void | crc_distortion_after_squash (struct render_compute *render, const struct comp_render_dispatch_data *d) |
For use after squashing layers. More... | |
static void | crc_distortion_fast_path (struct render_compute *render, const struct comp_render_dispatch_data *d, const struct comp_layer *layer, const struct xrt_layer_projection_view_data *vds[XRT_MAX_VIEWS]) |
Fast path. More... | |
void | comp_render_cs_layer (struct render_compute *render, uint32_t view_index, const struct comp_layer *layers, const uint32_t layer_count, const struct xrt_normalized_rect *pre_transform, const struct xrt_pose *world_pose, const struct xrt_pose *eye_pose, const VkImage target_image, const VkImageView target_image_view, const struct render_viewport_data *target_view, bool do_timewarp) |
Dispatch the layer squasher for a single view. More... | |
void | comp_render_cs_layers (struct render_compute *render, const struct comp_layer *layers, const uint32_t layer_count, const struct comp_render_dispatch_data *d, VkImageLayout transition_to) |
Dispatch the layer squasher, on any number of views. More... | |
void | comp_render_cs_dispatch (struct render_compute *render, const struct comp_layer *layers, const uint32_t layer_count, const struct comp_render_dispatch_data *d) |
Write commands to render to do a full composition with distortion. More... | |
Compositor (compute shader) rendering code.
|
static |
For use after squashing layers.
References comp_render_dispatch_data::view_count.
|
static |
Fast path.
|
inlinestatic |
Data setup for a cylinder layer.
References xrt_sub_image::array_index, and comp_layer::data.
|
inlinestatic |
Data setup for an "equirect2" layer.
References xrt_sub_image::array_index, and comp_layer::data.
|
inlinestatic |
Data setup for a projection layer.
References comp_layer::data, and xrt_layer_data::type.
|
inlinestatic |
Data setup for a quad layer.
References xrt_sub_image::array_index, and comp_layer::data.