Fix vulkan error on queue transfer

Queue transfer acquire was performed by each encoder, it needs to be
done only once, for the first one.
This commit is contained in:
Patrick Nicolas
2026-01-30 16:29:53 +01:00
parent f6d151c040
commit 2919f7d820
13 changed files with 56 additions and 45 deletions
+9 -2
View File
@@ -120,7 +120,10 @@ public:
// return value: true if image should be transitioned to queue and layout for vulkan video encode
// semaphore to be signaled by the compositor
std::pair<bool, vk::Semaphore> present_image(vk::Image y_cbcr, vk::raii::CommandBuffer & cmd_buf, uint64_t frame_index);
std::pair<bool, vk::Semaphore> present_image(vk::Image y_cbcr,
bool transferred,
vk::raii::CommandBuffer & cmd_buf,
uint64_t frame_index);
void post_submit();
void on_feedback(const from_headset::feedback &);
@@ -134,7 +137,11 @@ public:
uint64_t frame_index);
// called on present to submit command buffers for the image.
virtual std::pair<bool, vk::Semaphore> present_image(vk::Image y_cbcr, vk::raii::CommandBuffer & cmd_buf, uint8_t slot, uint64_t frame_index) = 0;
virtual std::pair<bool, vk::Semaphore> present_image(vk::Image y_cbcr,
bool transferred,
vk::raii::CommandBuffer & cmd_buf,
uint8_t slot,
uint64_t frame_index) = 0;
// called after command buffer passed in present_image was submitted
virtual void post_submit(uint8_t slot) {}
// called when command buffer finished executing