Expand submit info

This commit is contained in:
hodasemi 2023-12-04 11:09:57 +01:00
parent f318ae03fd
commit 492ec7ff04

View file

@ -213,6 +213,12 @@ impl SubmitInfo {
self self
} }
pub fn add_wait_semaphore_vk(mut self, wait_semaphore: VkSemaphore) -> Self {
self.wait_semaphores.push(wait_semaphore);
self
}
pub fn add_wait_stage(mut self, wait_stage: impl Into<VkPipelineStageFlagBits>) -> Self { pub fn add_wait_stage(mut self, wait_stage: impl Into<VkPipelineStageFlagBits>) -> Self {
self.wait_stages.push(wait_stage.into()); self.wait_stages.push(wait_stage.into());
@ -231,6 +237,12 @@ impl SubmitInfo {
self self
} }
pub fn add_signal_semaphore_vk(mut self, signal_semaphore: VkSemaphore) -> Self {
self.signal_semaphores.push(signal_semaphore);
self
}
pub fn as_vk_submit(&self) -> VkSubmitInfo { pub fn as_vk_submit(&self) -> VkSubmitInfo {
VkSubmitInfo::new( VkSubmitInfo::new(
self.wait_semaphores.as_slice(), self.wait_semaphores.as_slice(),