52#define RENDER_ALWAYS_SAFE_UBO_ALIGNMENT (256)
58#define RENDER_MAX_LAYERS (XRT_MAX_LAYERS)
64#define RENDER_MAX_IMAGES_SIZE (RENDER_MAX_LAYERS * XRT_MAX_VIEWS)
65#define RENDER_MAX_IMAGES_COUNT(RENDER_RESOURCES) (RENDER_MAX_LAYERS * RENDER_RESOURCES->view_count)
74#define RENDER_MAX_LAYER_RUNS_SIZE (XRT_MAX_VIEWS)
75#define RENDER_MAX_LAYER_RUNS_COUNT(RENDER_RESOURCES) (RENDER_RESOURCES->view_count)
78#define RENDER_DISTORTION_IMAGE_DIMENSIONS (128)
81#define RENDER_DISTORTION_IMAGES_SIZE (3 * XRT_MAX_VIEWS)
82#define RENDER_DISTORTION_IMAGES_COUNT(RENDER_RESOURCES) (3 * RENDER_RESOURCES->view_count)
85#define RENDER_BINDING_LAYER_SHARED_UBO 0
88#define RENDER_BINDING_LAYER_SHARED_SRC 1
137 VkShaderModule blit_comp;
138 VkShaderModule clear_comp;
139 VkShaderModule layer_comp;
140 VkShaderModule distortion_comp;
142 VkShaderModule mesh_vert;
143 VkShaderModule mesh_frag;
150 VkShaderModule layer_cylinder_vert;
151 VkShaderModule layer_cylinder_frag;
153 VkShaderModule layer_equirect2_vert;
154 VkShaderModule layer_equirect2_frag;
156 VkShaderModule layer_projection_vert;
157 VkShaderModule layer_quad_vert;
158 VkShaderModule layer_shared_frag;
209 VkBufferUsageFlags usage_flags,
210 VkMemoryPropertyFlags memory_property_flags,
219 VkBufferUsageFlags usage_flags,
220 VkMemoryPropertyFlags memory_property_flags,
323XRT_CHECK_RESULT VkResult
334XRT_CHECK_RESULT VkResult
377 VkCommandPool cmd_pool;
379 VkQueryPool query_pool;
448 uint32_t vertex_count;
449 uint32_t index_counts[XRT_MAX_VIEWS];
451 uint32_t index_offsets[XRT_MAX_VIEWS];
452 uint32_t index_count_total;
467 VkImageView image_view;
644 VkDeviceMemory device_memory;
646 VkImageView srgb_view;
647 VkImageView unorm_view;
735 VkPipeline cylinder_premultiplied_alpha;
736 VkPipeline cylinder_unpremultiplied_alpha;
738 VkPipeline equirect2_premultiplied_alpha;
739 VkPipeline equirect2_unpremultiplied_alpha;
741 VkPipeline proj_premultiplied_alpha;
742 VkPipeline proj_unpremultiplied_alpha;
744 VkPipeline quad_premultiplied_alpha;
745 VkPipeline quad_unpremultiplied_alpha;
758 VkAttachmentLoadOp load_op,
759 VkImageLayout final_layout);
943 float central_horizontal_angle;
944 float upper_vertical_angle;
945 float lower_vertical_angle;
986XRT_CHECK_RESULT VkResult
989 VkSampler src_sampler,
990 VkImageView src_image_view,
991 VkDescriptorSet *out_descriptor_set);
999XRT_CHECK_RESULT VkResult
1002 VkSampler src_sampler,
1003 VkImageView src_image_view,
1004 VkDescriptorSet *out_descriptor_set);
1012XRT_CHECK_RESULT VkResult
1015 VkSampler src_sampler,
1016 VkImageView src_image_view,
1017 VkDescriptorSet *out_descriptor_set);
1025XRT_CHECK_RESULT VkResult
1028 VkSampler src_sampler,
1029 VkImageView src_image_view,
1030 VkDescriptorSet *out_descriptor_set);
1038XRT_CHECK_RESULT VkResult
1041 VkSampler src_sampler,
1042 VkImageView src_image_view,
1043 VkDescriptorSet *out_descriptor_set);
1065 const VkClearColorValue *color);
1214 uint32_t unpremultiplied;
1215 uint32_t
padding[XRT_MAX_VIEWS];
1221 uint32_t images[XRT_MAX_VIEWS];
1223 uint32_t
padding[XRT_MAX_VIEWS];
1236 float central_angle;
1248 float central_horizontal_angle;
1249 float upper_vertical_angle;
1250 float lower_vertical_angle;
1348 VkDescriptorSet descriptor_set,
1353 VkImageView target_image_view,
1362 VkSampler src_samplers[XRT_MAX_VIEWS],
1363 VkImageView src_image_views[XRT_MAX_VIEWS],
1365 const struct xrt_pose src_poses[XRT_MAX_VIEWS],
1366 const struct xrt_fov src_fovs[XRT_MAX_VIEWS],
1367 const struct xrt_pose new_poses[XRT_MAX_VIEWS],
1368 VkImage target_image,
1369 VkImageView target_image_view,
1377 VkSampler src_samplers[XRT_MAX_VIEWS],
1378 VkImageView src_image_views[XRT_MAX_VIEWS],
1380 VkImage target_image,
1381 VkImageView target_image_view,
1389 VkImage target_image,
1390 VkImageView target_image_view,
bool render_resources_init(struct render_resources *r, struct render_shaders *shaders, struct vk_bundle *vk, struct xrt_device *xdev)
Allocate pools and static resources.
Definition: render_resources.c:509
VkResult render_buffer_map_and_write(struct vk_bundle *vk, struct render_buffer *buffer, void *data, VkDeviceSize size)
Maps the buffer, and copies the given data to the buffer.
Definition: render_buffer.c:209
#define RENDER_MAX_LAYER_RUNS_SIZE
Maximum number of times that the layer squasher shader can run per render_compute.
Definition: render_interface.h:74
VkResult render_buffer_write(struct vk_bundle *vk, struct render_buffer *buffer, void *data, VkDeviceSize size)
Writes the given data to the buffer, will map it temporarily if not mapped.
Definition: render_buffer.c:231
void render_gfx_end_view(struct render_gfx *render)
Definition: render_gfx.c:1137
void render_gfx_mesh_draw(struct render_gfx *render, uint32_t mesh_index, VkDescriptorSet descriptor_set, bool do_timewarp)
Dispatch one mesh shader instance, using the give mesh_index as source for mesh geometry,...
Definition: render_gfx.c:1166
bool render_gfx_end(struct render_gfx *render)
Frees any unneeded resources and ends the command buffer so it can be used, also unlocks the vk_bundl...
Definition: render_gfx.c:1007
XRT_CHECK_RESULT VkResult render_gfx_layer_equirect2_alloc_and_write(struct render_gfx *render, const struct render_gfx_layer_equirect2_data *data, VkSampler src_sampler, VkImageView src_image_view, VkDescriptorSet *out_descriptor_set)
Allocate and write a UBO and descriptor_set to be used for equirect2 layer rendering,...
Definition: render_gfx.c:1271
void render_gfx_begin_view(struct render_gfx *render, uint32_t view, const struct render_viewport_data *viewport_data)
Definition: render_gfx.c:1086
void render_gfx_layer_equirect2(struct render_gfx *render, bool premultiplied_alpha, VkDescriptorSet descriptor_set)
Dispatch a equirect2 layer shader into the current target and view.
Definition: render_gfx.c:1361
void render_shaders_fini(struct render_shaders *s, struct vk_bundle *vk)
Unload and cleanup shaders.
Definition: render_shaders.c:129
XRT_CHECK_RESULT VkResult render_gfx_layer_cylinder_alloc_and_write(struct render_gfx *render, const struct render_gfx_layer_cylinder_data *data, VkSampler src_sampler, VkImageView src_image_view, VkDescriptorSet *out_descriptor_set)
Allocate and write a UBO and descriptor_set to be used for cylinder layer rendering,...
Definition: render_gfx.c:1249
bool render_resources_get_timestamps(struct render_resources *r, uint64_t *out_gpu_start_ns, uint64_t *out_gpu_end_ns)
Returns the timestamps for when the latest GPU work started and stopped that was submitted using rend...
Definition: render_resources.c:1147
void render_gfx_fini(struct render_gfx *render)
Frees all resources held by the rendering, does not free the struct itself.
Definition: render_gfx.c:1025
void render_distortion_images_fini(struct render_resources *r)
Free distortion images.
Definition: render_distortion.c:393
void render_calc_time_warp_matrix(const struct xrt_pose *src_pose, const struct xrt_fov *src_fov, const struct xrt_pose *new_pose, struct xrt_matrix_4x4 *matrix)
Calculates a timewarp matrix which takes in NDC coords and gives out results in [-1,...
Definition: render_util.c:91
bool render_gfx_target_resources_init(struct render_gfx_target_resources *rtr, struct render_resources *r, struct render_gfx_render_pass *rgrp, VkImageView target, VkExtent2D extent)
Init a target resource struct, caller has to keep target alive until closed.
Definition: render_gfx.c:915
bool render_compute_end(struct render_compute *render)
Frees any unneeded resources and ends the command buffer so it can be used, also unlocks the vk_bundl...
Definition: render_compute.c:356
#define RENDER_MAX_LAYERS
Max number of layers for layer squasher, can be different from XRT_MAX_LAYERS as the render module is...
Definition: render_interface.h:58
#define RENDER_DISTORTION_IMAGES_SIZE
How many distortion images we have, one for each channel (3 rgb) and per view.
Definition: render_interface.h:81
void render_calc_uv_to_tangent_lengths_rect(const struct xrt_fov *fov, struct xrt_normalized_rect *out_rect)
This function constructs a transformation in the form of a normalized rect that lets you go from a UV...
Definition: render_util.c:127
void render_gfx_target_resources_fini(struct render_gfx_target_resources *rtr)
Frees all resources held by the target, does not free the struct itself.
Definition: render_gfx.c:943
bool render_gfx_begin_target(struct render_gfx *render, struct render_gfx_target_resources *rtr, const VkClearColorValue *color)
This function allocates everything to start a single rendering.
Definition: render_gfx.c:1048
#define RENDER_MAX_IMAGES_SIZE
Max number of images that can be given at a single time to the layer squasher in a single dispatch.
Definition: render_interface.h:64
VkResult render_buffer_init(struct vk_bundle *vk, struct render_buffer *buffer, VkBufferUsageFlags usage_flags, VkMemoryPropertyFlags memory_property_flags, VkDeviceSize size)
Initialize a buffer.
Definition: render_buffer.c:118
bool render_gfx_begin(struct render_gfx *render)
Begins the rendering, takes the vk_bundle's pool lock and leaves it locked.
Definition: render_gfx.c:972
bool render_gfx_render_pass_init(struct render_gfx_render_pass *rgrp, struct render_resources *r, VkFormat format, VkAttachmentLoadOp load_op, VkImageLayout final_layout)
Creates all resources held by the render pass.
Definition: render_gfx.c:710
XRT_CHECK_RESULT VkResult render_gfx_layer_projection_alloc_and_write(struct render_gfx *render, const struct render_gfx_layer_projection_data *data, VkSampler src_sampler, VkImageView src_image_view, VkDescriptorSet *out_descriptor_set)
Allocate and write a UBO and descriptor_set to be used for projection layer rendering,...
Definition: render_gfx.c:1293
XRT_CHECK_RESULT VkResult render_gfx_layer_quad_alloc_and_write(struct render_gfx *render, const struct render_gfx_layer_quad_data *data, VkSampler src_sampler, VkImageView src_image_view, VkDescriptorSet *out_descriptor_set)
Allocate and write a UBO and descriptor_set to be used for quad layer rendering, the content of data ...
Definition: render_gfx.c:1315
void render_gfx_layer_projection(struct render_gfx *render, bool premultiplied_alpha, VkDescriptorSet descriptor_set)
Dispatch a projection layer shader into the current target and view.
Definition: render_gfx.c:1377
void render_resources_fini(struct render_resources *r)
Free all pools and static resources, does not free the struct itself.
Definition: render_resources.c:1084
bool render_compute_begin(struct render_compute *render)
Begin the compute command buffer building, takes the vk_bundle's pool lock and leaves it locked.
Definition: render_compute.c:322
bool render_compute_init(struct render_compute *render, struct render_resources *r)
Init struct and create resources needed for compute rendering.
Definition: render_compute.c:289
bool render_shaders_load(struct render_shaders *s, struct vk_bundle *vk)
Loads all of the shaders that the compositor uses.
Definition: render_shaders.c:102
void render_scratch_images_fini(struct render_resources *r, struct render_scratch_images *rsi)
Close all resources on the given render_scratch_images.
Definition: render_resources.c:1279
void render_gfx_end_target(struct render_gfx *render)
Definition: render_gfx.c:1074
void render_buffer_unmap(struct vk_bundle *vk, struct render_buffer *buffer)
Unmaps the memory.
Definition: render_buffer.c:200
bool render_resources_get_duration(struct render_resources *r, uint64_t *out_gpu_duration_ns)
Returns the duration for the latest GPU work that was submitted using render_gfx or render_compute cm...
Definition: render_resources.c:1200
void render_compute_fini(struct render_compute *render)
Frees all resources held by the compute rendering, does not free the struct itself.
Definition: render_compute.c:374
bool render_gfx_init(struct render_gfx *render, struct render_resources *r)
Init struct and create resources needed for rendering.
Definition: render_gfx.c:960
void render_gfx_render_pass_fini(struct render_gfx_render_pass *rgrp)
Frees all resources held by the render pass, does not free the struct itself.
Definition: render_gfx.c:887
void render_sub_alloc_tracker_init(struct render_sub_alloc_tracker *rsat, struct render_buffer *buffer)
Init a render_sub_alloc_tracker struct from a render_buffer, the caller is responsible for keeping bu...
Definition: render_sub_alloc.c:29
VkResult render_buffer_init_exportable(struct vk_bundle *vk, struct render_buffer *buffer, VkBufferUsageFlags usage_flags, VkMemoryPropertyFlags memory_property_flags, VkDeviceSize size)
Initialize a buffer, making it exportable.
Definition: render_buffer.c:144
XRT_CHECK_RESULT VkResult render_gfx_mesh_alloc_and_write(struct render_gfx *render, const struct render_gfx_mesh_ubo_data *data, VkSampler src_sampler, VkImageView src_image_view, VkDescriptorSet *out_descriptor_set)
Allocate needed resources for one mesh shader dispatch, will also update the descriptor set,...
Definition: render_gfx.c:1144
void render_gfx_layer_cylinder(struct render_gfx *render, bool premultiplied_alpha, VkDescriptorSet descriptor_set)
Dispatch a cylinder layer shader into the current target and view.
Definition: render_gfx.c:1337
bool render_distortion_images_ensure(struct render_resources *r, struct vk_bundle *vk, struct xrt_device *xdev, bool pre_rotate)
Creates or recreates the compute distortion textures if necessary.
Definition: render_distortion.c:405
VkResult render_buffer_map(struct vk_bundle *vk, struct render_buffer *buffer)
Maps the memory, sets render_buffer::mapped to the memory.
Definition: render_buffer.c:189
void render_gfx_layer_quad(struct render_gfx *render, bool premultiplied_alpha, VkDescriptorSet descriptor_set)
Dispatch a quad layer shader into the current target and view.
Definition: render_gfx.c:1393
void render_compute_layers(struct render_compute *render, VkDescriptorSet descriptor_set, VkBuffer ubo, VkSampler src_samplers[((XRT_MAX_LAYERS) *XRT_MAX_VIEWS)], VkImageView src_image_views[((XRT_MAX_LAYERS) *XRT_MAX_VIEWS)], uint32_t num_srcs, VkImageView target_image_view, const struct render_viewport_data *view, bool timewarp)
Updates the given descriptor_set and dispatches the layer shader.
XRT_CHECK_RESULT VkResult render_sub_alloc_ubo_alloc_and_get_ptr(struct vk_bundle *vk, struct render_sub_alloc_tracker *rsat, VkDeviceSize size, void **out_ptr, struct render_sub_alloc *out_rsa)
Allocate enough memory (with constraints of UBOs) of size, return the pointer to the mapped memory or...
Definition: render_sub_alloc.c:38
XRT_CHECK_RESULT VkResult render_sub_alloc_ubo_alloc_and_write(struct vk_bundle *vk, struct render_sub_alloc_tracker *rsat, const void *ptr, VkDeviceSize size, struct render_sub_alloc *out_rsa)
Allocate enough memory (with constraints of UBOs) to hold the memory in ptr and copy that memory to t...
Definition: render_sub_alloc.c:84
bool render_scratch_images_ensure(struct render_resources *r, struct render_scratch_images *rsi, VkExtent2D extent)
Ensure that the scratch images are created and have the given extent.
Definition: render_resources.c:1245
void render_buffer_fini(struct vk_bundle *vk, struct render_buffer *buffer)
Frees all resources that this buffer has, but does not free the buffer itself.
Definition: render_buffer.c:181
Helper struct holding a buffer and its memory.
Definition: render_interface.h:184
VkDeviceSize alignment
Alignment of the buffer.
Definition: render_interface.h:198
VkDeviceSize allocation_size
Size of the memory allocation.
Definition: render_interface.h:195
VkDeviceMemory memory
Backing memory.
Definition: render_interface.h:186
VkBuffer buffer
Buffer.
Definition: render_interface.h:189
VkDeviceSize size
Size requested for the buffer.
Definition: render_interface.h:192
Push data that is sent to the blit shader.
Definition: render_interface.h:1187
UBO data that is sent to the compute distortion shaders.
Definition: render_interface.h:1293
UBO data that is sent to the compute layer shaders.
Definition: render_interface.h:1198
struct xrt_matrix_4x4 transforms[(XRT_MAX_LAYERS)]
For projection layers.
Definition: render_interface.h:1259
struct render_compute_layer_ubo_data::@104 eq2_data[(XRT_MAX_LAYERS)]
For equirect2 layers.
struct render_compute_layer_ubo_data::@105 quad_position[(XRT_MAX_LAYERS)]
For quad layers.
struct xrt_matrix_4x4 mv_inverse[(XRT_MAX_LAYERS)]
Shared between cylinder and equirect2.
Definition: render_interface.h:1227
struct render_compute_layer_ubo_data::@107 quad_extent[(XRT_MAX_LAYERS)]
Quad extent in world scale.
struct render_compute_layer_ubo_data::@103 cylinder_data[(XRT_MAX_LAYERS)]
For cylinder layer.
uint32_t padding[3]
Definition: render_interface.h:1204
struct render_compute_layer_ubo_data::@102 images_samplers[(XRT_MAX_LAYERS)]
Which image/sampler(s) correspond to each layer.
struct render_compute_layer_ubo_data::@101 layer_type[(XRT_MAX_LAYERS)]
std140 uvec2, corresponds to enum xrt_layer_type and unpremultiplied alpha.
The semi-low level resources and operations required to squash layers and/or apply distortion for a s...
Definition: render_interface.h:1166
struct render_resources * r
Shared resources.
Definition: render_interface.h:1168
VkDescriptorSet shared_descriptor_set
Shared descriptor set, used for the clear and distortion shaders.
Definition: render_interface.h:1178
VkDescriptorSet layer_descriptor_sets[(XRT_MAX_VIEWS)]
Layer descriptor set.
Definition: render_interface.h:1171
UBO data that is sent to the layer cylinder shader.
Definition: render_interface.h:920
UBO data that is sent to the layer equirect2 shader.
Definition: render_interface.h:935
struct xrt_normalized_rect to_tangent
See render_calc_uv_to_tangent_lengths_rect.
Definition: render_interface.h:940
UBO data that is sent to the layer projection shader.
Definition: render_interface.h:954
UBO data that is sent to the layer quad shader.
Definition: render_interface.h:966
UBO data that is sent to the mesh shaders.
Definition: render_interface.h:905
A render pass, while not depending on a VkFramebuffer, does depend on the format of the target image(...
Definition: render_interface.h:706
VkPipeline pipeline
Pipeline layout used for mesh, without timewarp.
Definition: render_interface.h:727
VkFormat format
The format of the image(s) we are rendering to.
Definition: render_interface.h:710
VkSampleCountFlagBits sample_count
Sample count for this render pass.
Definition: render_interface.h:713
VkAttachmentLoadOp load_op
Load op used on the attachment(s).
Definition: render_interface.h:716
VkImageLayout final_layout
Final layout of the target image(s).
Definition: render_interface.h:719
VkRenderPass render_pass
Render pass used for rendering.
Definition: render_interface.h:722
VkPipeline pipeline_timewarp
Pipeline layout used for mesh, with timewarp.
Definition: render_interface.h:730
Each rendering (render_gfx) render to one or more targets (render_gfx_target_resources),...
Definition: render_interface.h:785
struct render_resources * r
Collections of static resources.
Definition: render_interface.h:787
struct render_gfx_render_pass * rgrp
Render pass.
Definition: render_interface.h:790
VkFramebuffer framebuffer
Framebuffer for this target, depends on given VkImageView.
Definition: render_interface.h:796
The low-level resources and operations to perform layer squashing and/or mesh distortion for a single...
Definition: render_interface.h:848
struct render_resources * r
Resources that we are based on.
Definition: render_interface.h:850
struct render_gfx_target_resources * rtr
The current target we are rendering to, can change during command building.
Definition: render_interface.h:856
struct render_sub_alloc_tracker ubo_tracker
Shared buffer that we sub-allocate UBOs from.
Definition: render_interface.h:853
Holds all pools and static resources for rendering.
Definition: render_interface.h:352
uint32_t target_binding
Writing the image out too.
Definition: render_interface.h:484
uint32_t ubo_binding
The binding index for the UBO.
Definition: render_interface.h:437
VkCommandBuffer cmd
Command buffer for recording everything.
Definition: render_interface.h:387
uint32_t image_array_size
Size of combined image sampler array.
Definition: render_interface.h:504
uint32_t view_count
The count of views that we are rendering to.
Definition: render_interface.h:354
struct render_buffer ubos[XRT_MAX_VIEWS]
Info UBOs.
Definition: render_interface.h:455
struct vk_bundle * vk
Vulkan resources.
Definition: render_interface.h:357
VkSampler clamp_to_border_black
Sampler that clamps color samples to black in all directions.
Definition: render_interface.h:401
bool pre_rotated
Whether distortion images have been pre-rotated 90 degrees.
Definition: render_interface.h:555
VkPipeline non_timewarp_pipeline
Doesn't depend on target so is static.
Definition: render_interface.h:498
struct render_shaders * shaders
All shaders loaded.
Definition: render_interface.h:364
struct render_buffer shared_ubo
Shared UBO buffer that we sub-allocate out of, this is to have fewer buffers that the kernel needs to...
Definition: render_interface.h:416
VkDescriptorSetLayout descriptor_set_layout
For projection and quad layer.
Definition: render_interface.h:423
struct xrt_normalized_rect uv_to_tanangle[XRT_MAX_VIEWS]
Transform to go from UV to tangle angles.
Definition: render_interface.h:543
VkPipeline timewarp_pipeline
Doesn't depend on target so is static.
Definition: render_interface.h:501
VkPipeline pipeline
Doesn't depend on target so is static.
Definition: render_interface.h:519
VkImage images[(3 *XRT_MAX_VIEWS)]
Distortion images.
Definition: render_interface.h:549
VkDescriptorPool ubo_and_src_descriptor_pool
Pool for shaders that uses one ubo and sampler.
Definition: render_interface.h:407
struct vk_cmd_pool distortion_pool
Pool used for distortion image uploads.
Definition: render_interface.h:372
VkSampler repeat
Sampler that repeats the texture in all directions.
Definition: render_interface.h:395
uint32_t src_binding
The binding index for the source texture.
Definition: render_interface.h:434
VkDeviceMemory device_memories[(3 *XRT_MAX_VIEWS)]
Backing memory to distortion images.
Definition: render_interface.h:546
VkSampler mock
Sampler for mock/null images.
Definition: render_interface.h:392
VkSampler clamp_to_edge
Sampler that clamps the coordinates to the edge in all directions.
Definition: render_interface.h:398
struct render_buffer ubo
Target info.
Definition: render_interface.h:525
uint32_t distortion_binding
Image storing the distortion.
Definition: render_interface.h:481
VkPipelineLayout pipeline_layout
For projection and quad layer.
Definition: render_interface.h:426
VkDescriptorPool descriptor_pool
Descriptor pool for compute work.
Definition: render_interface.h:475
VkPipelineCache pipeline_cache
Shared for all rendering.
Definition: render_interface.h:375
VkImageView image_views[(3 *XRT_MAX_VIEWS)]
The views into the distortion images.
Definition: render_interface.h:552
Small helper struct to hold a scratch image, intended to be used with the compute pipeline where both...
Definition: render_interface.h:643
Helper struct to hold scratch images.
Definition: render_interface.h:654
Holds all shaders.
Definition: render_interface.h:136
A per-frame tracker of sub-allocation out of a buffer, used to reduce the number of UBO objects we ne...
Definition: render_interface.h:294
void * mapped
Start of memory, if buffer was mapped with initialised.
Definition: render_interface.h:302
VkBuffer buffer
The buffer to allocate from, it is the caller's responsibility to keep it alive for as long as the su...
Definition: render_interface.h:299
VkDeviceSize used
Currently used memory.
Definition: render_interface.h:308
VkDeviceSize total_size
Total size of buffer.
Definition: render_interface.h:305
Per frame sub-allocation into a buffer, used to reduce the number of UBO objects we need to create.
Definition: render_interface.h:269
VkDeviceSize size
Size of sub-allocation.
Definition: render_interface.h:277
VkBuffer buffer
The buffer this is allocated from, it is the caller's responsibility to keep it alive for as long as ...
Definition: render_interface.h:274
VkDeviceSize offset
Offset into buffer.
Definition: render_interface.h:280
The pure data information about a view that the renderer is rendering to.
Definition: render_interface.h:687
A bundle of Vulkan functions and objects, used by both Compositor and Compositor client code.
Definition: vk_helpers.h:50
Small helper to manage lock around a command pool.
Definition: vk_cmd_pool.h:33
A single HMD or input device.
Definition: xrt_device.h:241
Describes a projection matrix fov.
Definition: xrt_defines.h:486
A tightly packed 2x2 matrix of floats.
Definition: xrt_defines.h:513
A tightly packed 4x4 matrix of floats.
Definition: xrt_defines.h:560
Normalized image rectangle, coordinates and size in 0 .
Definition: xrt_defines.h:453
A pose composed of a position and orientation.
Definition: xrt_defines.h:465
Image rectangle.
Definition: xrt_defines.h:430
A 2 element vector with single floats.
Definition: xrt_defines.h:250
A 3 element vector with single floats.
Definition: xrt_defines.h:271
Common Vulkan code header.
Header holding common defines.
Common defines and enums for XRT.