VKFREECOMMANDBUFFERS(3)

NAME
vkFreeCommandBuffers - Free command buffers.

C SPECIFICATION

    void vkFreeCommandBuffers(
        VkDevice                                    device,
        VkCommandPool                               commandPool,
        uint32_t                                    commandBufferCount,
        const VkCommandBuffer*                      pCommandBuffers);

PARAMETERS

device
    A handle to the device that owns the command pool and command buffers referenced by the command.

commandPool
    A handle to the command pool which owns the command buffers.

commandBufferCount
    The number of command buffers to free.

pCommandBuffers
    A pointer to an array of handles to the command buffers to free.

DESCRIPTION

vkFreeCommandBuffers frees commandBufferCount command buffers, returning their resources to the pool specified in commandPool. pCommandBuffers is a pointer to an array of commandBufferCount VkCommandBuffer handles to the command buffers to free. Each command buffer in the array must have been allocated from the pool specified in commandPool through a call to vkAllocateCommandBuffers. device must be a handle to the device that owns both commandPool and all of the command buffers referenced from the array pointed to by pCommandBuffers.

After command buffers are freed, they may not be referenced again. A command buffer must not be freed while it is in flight.

VALID USAGE

    • device must be a valid VkDevice handle

    • commandPool must be a valid VkCommandPool handle

    • commandBufferCount must be greater than 0

    • commandPool must have been created, allocated or retrieved from device

    • Each element of pCommandBuffers that is a valid handle must have been created, allocated or retrieved from commandPool

    • Each of device, commandPool and the elements of pCommandBuffers that are valid handles must have been created, allocated or retrieved from the same VkPhysicalDevice

    • All elements of pCommandBuffers must not be pending execution

    • pCommandBuffers must be a pointer to an array of commandBufferCount VkCommandBuffer handles, each element of which must either be a valid handle or VK_NULL_HANDLE

HOST SYNCHRONIZATION

    • Host access to commandPool must be externally synchronized

    • Host access to each member of pCommandBuffers must be externally synchronized

SEE ALSO

vkAllocateCommandBuffers, vkResetCommandBuffer, vkBeginCommandBuffer, vkEndCommandBuffer, vkQueueSubmit

COPYRIGHT

Copyright © 2014-2016 Khronos Group. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1.0, 8 June 1999. http://opencontent.org/openpub/.

AUTHOR

Khronos Group
    Author.