| 21 | } |
| 22 | |
| 23 | void CmdBufferVulkan::Begin() |
| 24 | { |
| 25 | PROFILE_CPU(); |
| 26 | ASSERT(_state == State::ReadyForBegin); |
| 27 | |
| 28 | VkCommandBufferBeginInfo beginInfo; |
| 29 | RenderToolsVulkan::ZeroStruct(beginInfo, VK_STRUCTURE_TYPE_COMMAND_BUFFER_BEGIN_INFO); |
| 30 | beginInfo.flags = VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT; |
| 31 | VALIDATE_VULKAN_RESULT(vkBeginCommandBuffer(_commandBuffer, &beginInfo)); |
| 32 | |
| 33 | // Acquire a descriptor pool set on |
| 34 | if (_descriptorPoolSetContainer == nullptr) |
| 35 | { |
| 36 | _descriptorPoolSetContainer = _device->DescriptorPoolsManager->AcquirePoolSetContainer(); |
| 37 | } |
| 38 | |
| 39 | _state = State::IsInsideBegin; |
| 40 | |
| 41 | #if GPU_ALLOW_PROFILE_EVENTS |
| 42 | // Reset events counter |
| 43 | _eventsBegin = 0; |
| 44 | #endif |
| 45 | } |
| 46 | |
| 47 | void CmdBufferVulkan::End() |
| 48 | { |
no test coverage detected