mirror of
https://github.com/PancakeTAS/lsfg-vk.git
synced 2025-10-30 07:01:10 +00:00
refactor: completely remove default operators
they're just defaults anyways.. no need to be this verbose
This commit is contained in:
parent
1b367f7743
commit
c3cccb4967
14 changed files with 0 additions and 119 deletions
|
|
@ -49,13 +49,6 @@ namespace VK::Core {
|
|||
[[nodiscard]] auto getMemory() const { return *this->memory; }
|
||||
/// Get the size of the buffer.
|
||||
[[nodiscard]] auto getSize() const { return this->size; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
Buffer(const Buffer&) noexcept = default;
|
||||
Buffer& operator=(const Buffer&) noexcept = default;
|
||||
Buffer(Buffer&&) noexcept = default;
|
||||
Buffer& operator=(Buffer&&) noexcept = default;
|
||||
~Buffer() = default;
|
||||
private:
|
||||
|
||||
std::shared_ptr<VkBuffer> buffer;
|
||||
|
|
|
|||
|
|
@ -125,13 +125,6 @@ namespace VK::Core {
|
|||
[[nodiscard]] auto getState() const { return *this->state; }
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->commandBuffer; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
CommandBuffer(const CommandBuffer&) noexcept = default;
|
||||
CommandBuffer& operator=(const CommandBuffer&) noexcept = default;
|
||||
CommandBuffer(CommandBuffer&&) noexcept = default;
|
||||
CommandBuffer& operator=(CommandBuffer&&) noexcept = default;
|
||||
~CommandBuffer() = default;
|
||||
private:
|
||||
std::shared_ptr<CommandBufferState> state;
|
||||
std::shared_ptr<VkCommandBuffer> commandBuffer;
|
||||
|
|
|
|||
|
|
@ -28,13 +28,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->commandPool; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
CommandPool(const CommandPool&) noexcept = default;
|
||||
CommandPool& operator=(const CommandPool&) noexcept = default;
|
||||
CommandPool(CommandPool&&) noexcept = default;
|
||||
CommandPool& operator=(CommandPool&&) noexcept = default;
|
||||
~CommandPool() = default;
|
||||
private:
|
||||
std::shared_ptr<VkCommandPool> commandPool;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -28,13 +28,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->descriptorPool; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
DescriptorPool(const DescriptorPool&) noexcept = default;
|
||||
DescriptorPool& operator=(const DescriptorPool&) noexcept = default;
|
||||
DescriptorPool(DescriptorPool&&) noexcept = default;
|
||||
DescriptorPool& operator=(DescriptorPool&&) noexcept = default;
|
||||
~DescriptorPool() = default;
|
||||
private:
|
||||
std::shared_ptr<VkDescriptorPool> descriptorPool;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -27,13 +27,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return &this->info; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
ImageInfo(const ImageInfo&) noexcept = default;
|
||||
ImageInfo& operator=(const ImageInfo&) noexcept = default;
|
||||
ImageInfo(ImageInfo&&) noexcept = default;
|
||||
ImageInfo& operator=(ImageInfo&&) noexcept = default;
|
||||
~ImageInfo() = default;
|
||||
private:
|
||||
VkDescriptorImageInfo info{};
|
||||
};
|
||||
|
|
@ -48,13 +41,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return &this->info; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
SamplerInfo(const SamplerInfo&) noexcept = default;
|
||||
SamplerInfo& operator=(const SamplerInfo&) noexcept = default;
|
||||
SamplerInfo(SamplerInfo&&) noexcept = default;
|
||||
SamplerInfo& operator=(SamplerInfo&&) noexcept = default;
|
||||
~SamplerInfo() = default;
|
||||
private:
|
||||
VkDescriptorImageInfo info{};
|
||||
};
|
||||
|
|
@ -70,13 +56,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return &this->info; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
BufferInfo(const BufferInfo&) noexcept = default;
|
||||
BufferInfo& operator=(const BufferInfo&) noexcept = default;
|
||||
BufferInfo(BufferInfo&&) noexcept = default;
|
||||
BufferInfo& operator=(BufferInfo&&) noexcept = default;
|
||||
~BufferInfo() = default;
|
||||
private:
|
||||
VkDescriptorBufferInfo info{};
|
||||
};
|
||||
|
|
@ -108,13 +87,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->descriptorSet; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
DescriptorSet(const DescriptorSet&) noexcept = default;
|
||||
DescriptorSet& operator=(const DescriptorSet&) noexcept = default;
|
||||
DescriptorSet(DescriptorSet&&) noexcept = default;
|
||||
DescriptorSet& operator=(DescriptorSet&&) noexcept = default;
|
||||
~DescriptorSet() = default;
|
||||
private:
|
||||
std::shared_ptr<VkDescriptorSet> descriptorSet;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -56,13 +56,6 @@ namespace VK::Core {
|
|||
[[nodiscard]] auto getComputeFamilyIdx() const { return this->computeFamilyIdx; }
|
||||
/// Check if the device supports FP16.
|
||||
[[nodiscard]] auto supportsFP16() const { return this->fp16; }
|
||||
|
||||
// Trivially copyable, moveable and destructible
|
||||
Device(const Device&) noexcept = default;
|
||||
Device& operator=(const Device&) noexcept = default;
|
||||
Device(Device&&) noexcept = default;
|
||||
Device& operator=(Device&&) noexcept = default;
|
||||
~Device() = default;
|
||||
private:
|
||||
std::shared_ptr<VkDevice> device;
|
||||
|
||||
|
|
|
|||
|
|
@ -49,13 +49,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->fence; }
|
||||
|
||||
// Trivially copyable, moveable and destructible
|
||||
Fence(const Fence&) noexcept = default;
|
||||
Fence& operator=(const Fence&) noexcept = default;
|
||||
Fence(Fence&&) noexcept = default;
|
||||
Fence& operator=(Fence&&) noexcept = default;
|
||||
~Fence() = default;
|
||||
private:
|
||||
std::shared_ptr<VkFence> fence;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -82,13 +82,6 @@ namespace VK::Core {
|
|||
void setLayout(VkImageLayout layout) { *this->layout = layout; }
|
||||
/// Get the current layout of the image.
|
||||
[[nodiscard]] VkImageLayout getLayout() const { return *this->layout; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
Image(const Image&) noexcept = default;
|
||||
Image& operator=(const Image&) noexcept = default;
|
||||
Image(Image&&) noexcept = default;
|
||||
Image& operator=(Image&&) noexcept = default;
|
||||
~Image() = default;
|
||||
private:
|
||||
std::shared_ptr<VkImage> image;
|
||||
std::shared_ptr<VkDeviceMemory> memory;
|
||||
|
|
|
|||
|
|
@ -22,13 +22,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->instance; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
Instance(const Instance&) noexcept = default;
|
||||
Instance& operator=(const Instance&) noexcept = default;
|
||||
Instance(Instance&&) noexcept = default;
|
||||
Instance& operator=(Instance&&) noexcept = default;
|
||||
~Instance() = default;
|
||||
private:
|
||||
std::shared_ptr<VkInstance> instance;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -32,13 +32,6 @@ namespace VK::Core {
|
|||
[[nodiscard]] auto handle() const { return *this->pipeline; }
|
||||
/// Get the pipeline layout.
|
||||
[[nodiscard]] auto getLayout() const { return *this->layout; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
Pipeline(const Pipeline&) noexcept = default;
|
||||
Pipeline& operator=(const Pipeline&) noexcept = default;
|
||||
Pipeline(Pipeline&&) noexcept = default;
|
||||
Pipeline& operator=(Pipeline&&) noexcept = default;
|
||||
~Pipeline() = default;
|
||||
private:
|
||||
std::shared_ptr<VkPipeline> pipeline;
|
||||
std::shared_ptr<VkPipelineLayout> layout;
|
||||
|
|
|
|||
|
|
@ -32,13 +32,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->sampler; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
Sampler(const Sampler&) noexcept = default;
|
||||
Sampler& operator=(const Sampler&) noexcept = default;
|
||||
Sampler(Sampler&&) noexcept = default;
|
||||
Sampler& operator=(Sampler&&) noexcept = default;
|
||||
~Sampler() = default;
|
||||
private:
|
||||
std::shared_ptr<VkSampler> sampler;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -30,13 +30,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->semaphore; }
|
||||
|
||||
// Trivially copyable, moveable and destructible
|
||||
Semaphore(const Semaphore&) noexcept = default;
|
||||
Semaphore& operator=(const Semaphore&) noexcept = default;
|
||||
Semaphore(Semaphore&&) noexcept = default;
|
||||
Semaphore& operator=(Semaphore&&) noexcept = default;
|
||||
~Semaphore() = default;
|
||||
private:
|
||||
std::shared_ptr<VkSemaphore> semaphore;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -37,13 +37,6 @@ namespace VK::Core {
|
|||
[[nodiscard]] auto handle() const { return *this->shaderModule; }
|
||||
/// Get the descriptor set layout.
|
||||
[[nodiscard]] auto getLayout() const { return *this->descriptorSetLayout; }
|
||||
|
||||
/// Trivially copyable, moveable and destructible
|
||||
ShaderModule(const ShaderModule&) noexcept = default;
|
||||
ShaderModule& operator=(const ShaderModule&) noexcept = default;
|
||||
ShaderModule(ShaderModule&&) noexcept = default;
|
||||
ShaderModule& operator=(ShaderModule&&) noexcept = default;
|
||||
~ShaderModule() = default;
|
||||
private:
|
||||
std::shared_ptr<VkShaderModule> shaderModule;
|
||||
std::shared_ptr<VkDescriptorSetLayout> descriptorSetLayout;
|
||||
|
|
|
|||
|
|
@ -53,13 +53,6 @@ namespace VK::Core {
|
|||
|
||||
/// Get the Vulkan handle.
|
||||
[[nodiscard]] auto handle() const { return *this->semaphore; }
|
||||
|
||||
// Trivially copyable, moveable and destructible
|
||||
TimelineSemaphore(const TimelineSemaphore&) noexcept = default;
|
||||
TimelineSemaphore& operator=(const TimelineSemaphore&) noexcept = default;
|
||||
TimelineSemaphore(TimelineSemaphore&&) noexcept = default;
|
||||
TimelineSemaphore& operator=(TimelineSemaphore&&) noexcept = default;
|
||||
~TimelineSemaphore() = default;
|
||||
private:
|
||||
std::shared_ptr<VkSemaphore> semaphore;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue