upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/src/vulkan_present_splash.h
diff options
context:
space:
mode:
authorTauwni <102470988+Tauwni@users.noreply.github.com>2026-11-26 12:19:12 +0100
committerTauwni <102470988+Tauwni@users.noreply.github.com>2026-11-26 12:19:12 +0100
commitbeffaa9a476ca1b3dfd9cfa55e39eafbb1f5eec6 (patch)
tree32877805bf4eb46d9a89d5753db6b5a2b06dc845 /runtime/src/vulkan_present_splash.h
parentf29ca7bacae9507f83e8c56abdb604bd4efb4cf1 (diff)
parenta73a57e1339be072baf5522351c8ec7f1482b56b (diff)
Merge main into fix/null-descriptor-generated-dir
Diffstat (limited to 'runtime/src/vulkan_present_splash.h')
-rw-r--r--runtime/src/vulkan_present_splash.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/runtime/src/vulkan_present_splash.h b/runtime/src/vulkan_present_splash.h
index affc9a92b..450b06296 100644
--- a/runtime/src/vulkan_present_splash.h
+++ b/runtime/src/vulkan_present_splash.h
@@ -13,7 +13,7 @@ inline bool VulkanPresenter::present_splash(ResourceId source, std::shared_ptr<v
13 if (!binding || !binding->image) return false; 13 if (!binding || !binding->image) return false;
14 splash_binding_ = *binding; 14 splash_binding_ = *binding;
15 } 15 }
16 if (!capture_) splash_capture_only_ = enable_capture(); 16 if (!capture_) splash_capture_only_ = enable_capture_storage();
17 const auto before = presented(); 17 const auto before = presented();
18 if (present(source, true) != VK_SUCCESS || presented() == before) return false; 18 if (present(source, true) != VK_SUCCESS || presented() == before) return false;
19 const Frame& frame = frames_[(frame_index_ - 1) % frames_.size()]; 19 const Frame& frame = frames_[(frame_index_ - 1) % frames_.size()];
@@ -61,14 +61,16 @@ inline VkResult VulkanPresenter::finish_startup_frame(Frame& frame, std::uint32_
61 VkSubmitInfo ready{VK_STRUCTURE_TYPE_SUBMIT_INFO}; 61 VkSubmitInfo ready{VK_STRUCTURE_TYPE_SUBMIT_INFO};
62 ready.signalSemaphoreCount = 1; 62 ready.signalSemaphoreCount = 1;
63 ready.pSignalSemaphores = &ready_[image]; 63 ready.pSignalSemaphores = &ready_[image];
64 if (show_title) return context_.vk.vkQueueSubmit(queue_, 1, &ready, VK_NULL_HANDLE); 64 if (show_title) return context_.queue_submit(queue_, 1, &ready, VK_NULL_HANDLE);
65 // The acquire was consumed and the title commands finished. Overwrite the same image before presenting it. 65 // The acquire was consumed and the title commands finished. Overwrite the same image before presenting it.
66 record(frame.commands, splash_binding_, splash_source_, image, nullptr); 66 // The inspected copy contains the black title frame. Overwrite staging with the
67 // splash actually shown; this is the copy an active disk/readback consumer must see.
68 record(frame.commands, splash_binding_, splash_source_, image, nullptr, true);
67 result = vkResetFences_(device, 1, &frame.done); 69 result = vkResetFences_(device, 1, &frame.done);
68 if (result != VK_SUCCESS) return result; 70 if (result != VK_SUCCESS) return result;
69 ready.commandBufferCount = 1; 71 ready.commandBufferCount = 1;
70 ready.pCommandBuffers = &frame.commands; 72 ready.pCommandBuffers = &frame.commands;
71 return context_.vk.vkQueueSubmit(queue_, 1, &ready, frame.done); 73 return context_.queue_submit(queue_, 1, &ready, frame.done);
72} 74}
73 75
74} // namespace leonida 76} // namespace leonida