MCPcopy Create free account
hub / github.com/Overv/VulkanTutorial / createCommandPool

Method createCommandPool

code/31_compute_shader.cpp:766–777  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

764 }
765
766 void createCommandPool() {
767 QueueFamilyIndices queueFamilyIndices = findQueueFamilies(physicalDevice);
768
769 VkCommandPoolCreateInfo poolInfo{};
770 poolInfo.sType = VK_STRUCTURE_TYPE_COMMAND_POOL_CREATE_INFO;
771 poolInfo.flags = VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT;
772 poolInfo.queueFamilyIndex = queueFamilyIndices.graphicsAndComputeFamily.value();
773
774 if (vkCreateCommandPool(device, &poolInfo, nullptr, &commandPool) != VK_SUCCESS) {
775 throw std::runtime_error("failed to create graphics command pool!");
776 }
777 }
778
779 void createShaderStorageBuffers() {
780

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected