MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-ValidationLayers / Allocate

Method Allocate

layers/state_tracker/cmd_buffer_state.cpp:129–135  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

127 unprotected((create_info->flags & VK_COMMAND_POOL_CREATE_PROTECTED_BIT) == 0) {}
128
129void CommandPool::Allocate(const VkCommandBufferAllocateInfo* allocate_info, const VkCommandBuffer* command_buffers) {
130 for (uint32_t i = 0; i < allocate_info->commandBufferCount; i++) {
131 auto new_cb = dev_data.CreateCmdBufferState(command_buffers[i], allocate_info, *this);
132 commandBuffers.emplace(command_buffers[i], new_cb.get());
133 dev_data.Add(std::move(new_cb));
134 }
135}
136
137void CommandPool::Free(uint32_t count, const VkCommandBuffer* command_buffers) {
138 for (uint32_t i = 0; i < count; i++) {

Callers

nothing calls this directly

Calls 3

CreateCmdBufferStateMethod · 0.80
emplaceMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected