The open source OpenXR runtime
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

c/render: Free command buffer when closing rendering

+17
+17
src/xrt/compositor/render/comp_rendering.c
··· 507 507 NULL); // pDescriptorCopies 508 508 } 509 509 510 + static void 511 + destroy_command_buffer(struct vk_bundle *vk, VkCommandBuffer command_buffer) 512 + { 513 + os_mutex_lock(&vk->cmd_pool_mutex); 514 + 515 + vk->vkFreeCommandBuffers( // 516 + vk->device, // device 517 + vk->cmd_pool, // commandPool 518 + 1, // commandBufferCount 519 + &command_buffer); // pCommandBuffers 520 + 521 + os_mutex_unlock(&vk->cmd_pool_mutex); 522 + } 523 + 510 524 511 525 /* 512 526 * ··· 624 638 { 625 639 struct vk_bundle *vk = vk_from_rr(rr); 626 640 struct comp_resources *r = rr->r; 641 + 642 + destroy_command_buffer(vk, rr->cmd); 643 + rr->cmd = VK_NULL_HANDLE; 627 644 628 645 // Reclaimed by vkResetDescriptorPool. 629 646 rr->views[0].mesh.descriptor_set = VK_NULL_HANDLE;