To submit command buffers to a queue, call:
VkResult vkQueueSubmit( VkQueue queue, uint32_t submitCount, const VkSubmitInfo* pSubmits, VkFence fence);
queueis the queue that the command buffers will be submitted to.
submitCountis the number of elements in the
pSubmitsis a pointer to an array of VkSubmitInfo structures, each specifying a command buffer submission batch.
Submission can be a high overhead operation, and applications should
attempt to batch work together into as few calls to
vkQueueSubmit is a queue submission
command, with each batch defined by an element of
Batches begin execution in the order they appear in
pSubmits, but may
complete out of order.
Fence and semaphore operations submitted with vkQueueSubmit have additional ordering constraints compared to other submission commands, with dependencies involving previous and subsequent queue operations. Information about these additional constraints can be found in the semaphore and fence sections of the synchronization chapter.
The order that batches appear in
pSubmits is used to determine
submission order, and thus all the
implicit ordering guarantees that respect it.
Other than these implicit ordering guarantees and any explicit synchronization primitives, these batches may overlap or
otherwise execute out of order.
If any command buffer submitted to this queue is in the
executable state, it is moved to the
Once execution of all submissions of a command buffer complete, it moves
from the pending state, back to the
If a command buffer was recorded with the
VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT flag, it instead moves
back to the invalid state.
vkQueueSubmit fails, it may return
If it does, the implementation must ensure that the state and contents of
any resources or synchronization primitives referenced by the submitted
command buffers and any semaphores referenced by
unaffected by the call or its failure.
vkQueueSubmit fails in such a way that the implementation is unable
to make that guarantee, the implementation must return
See Lost Device.
For more information, see the Vulkan Specification
This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.
Copyright (c) 2014-2020 Khronos Group. This work is licensed under a Creative Commons Attribution 4.0 International License.