lsfg-vk/framegen/include/vk/core/commandpool.hpp
PancakeTAS c3cccb4967
refactor: completely remove default operators
they're just defaults anyways.. no need to be this verbose
2025-09-01 17:37:12 +02:00

35 lines
756 B
C++

#pragma once
#include "vk/core/device.hpp"
#include <vulkan/vulkan_core.h>
#include <memory>
namespace VK::Core {
///
/// C++ wrapper class for a Vulkan command pool.
///
/// This class manages the lifetime of a Vulkan command pool.
///
class CommandPool {
public:
CommandPool() noexcept = default;
///
/// Create the command pool.
///
/// @param device Vulkan device
///
/// @throws VK::vulkan_error if object creation fails.
///
CommandPool(const Device& device);
/// Get the Vulkan handle.
[[nodiscard]] auto handle() const { return *this->commandPool; }
private:
std::shared_ptr<VkCommandPool> commandPool;
};
}