Lugdunum  0.1.0
PipelineLayout.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include <memory>
4 #include <vector>
5 
7 
8 namespace lug {
9 namespace Graphics {
10 namespace Vulkan {
11 namespace API {
12 
13 class Device;
14 
15 namespace Builder {
16 
18 public:
19  PipelineLayout(const API::Device& device);
20 
21  PipelineLayout(const PipelineLayout&) = delete;
22  PipelineLayout(PipelineLayout&&) = delete;
23 
24  PipelineLayout& operator=(const PipelineLayout&) = delete;
26 
27  ~PipelineLayout() = default;
28 
29  // Setters
30  void setPushConstants(const std::vector<VkPushConstantRange>& pushConstants);
31  void setDescriptorSetLayouts(std::vector<API::DescriptorSetLayout> descriptorSetLayouts);
32 
33  // Build methods
34  bool build(API::PipelineLayout& instance, VkResult* returnResult = nullptr);
35  std::unique_ptr<API::PipelineLayout> build(VkResult* returnResult = nullptr);
36 
37 private:
39 
40  std::vector<VkPushConstantRange> _pushConstants{};
41  std::vector<API::DescriptorSetLayout> _descriptorSetLayouts{};
42 };
43 
45 
46 } // Builder
47 } // API
48 } // Vulkan
49 } // Graphics
50 } // lug
std::vector< API::DescriptorSetLayout > _descriptorSetLayouts
PipelineLayout & operator=(const PipelineLayout &)=delete
void setDescriptorSetLayouts(std::vector< API::DescriptorSetLayout > descriptorSetLayouts)
std::vector< VkPushConstantRange > _pushConstants
void setPushConstants(const std::vector< VkPushConstantRange > &pushConstants)
void pushConstants(const CmdPushConstants &parameters) const
bool build(API::PipelineLayout &instance, VkResult *returnResult=nullptr)