15 const VkCommandPoolCreateInfo createInfo{
16 VK_STRUCTURE_TYPE_COMMAND_POOL_CREATE_INFO,
23 VkCommandPool vkCommandPool{VK_NULL_HANDLE};
24 VkResult result = vkCreateCommandPool(static_cast<VkDevice>(
_device), &createInfo,
nullptr, &vkCommandPool);
27 *returnResult = result;
30 if (result != VK_SUCCESS) {
40 std::unique_ptr<API::CommandPool> commandPool = std::make_unique<API::CommandPool>();
41 return build(*commandPool, returnResult) ? std::move(commandPool) :
nullptr;
const API::QueueFamily & _queueFamily
bool build(API::CommandPool &instance, VkResult *returnResult=nullptr)
const API::Device & _device
VkCommandPoolCreateFlags _flags
CommandPool(const API::Device &device, const API::QueueFamily &queueFamily)