#pragma once #include "forward.hpp" #include namespace render::vk { class SwapChain; class Pipeline; class CommandPool { public: CommandPool(VkDevice, const std::vector&, PipelineRef, const PhysicalDeviceInfo&, const renderOptions&); ~CommandPool(); void submitGraphics(uint32_t, VkQueue, VkSemaphore, VkSemaphore, VkFence); void allocate(const std::vector&, PipelineRef, VkExtent2D, const renderOptions&); void free(); private: VkDevice device; std::vector framebuffers; VkCommandPool graphicsPool; std::vector graphicsBuffers; bool freed = true; }; }