]> git.tdb.fi Git - libs/gl.git/blob - source/backends/vulkan/framebuffer_backend.h
Make framebuffer attachment accessors public
[libs/gl.git] / source / backends / vulkan / framebuffer_backend.h
1 #ifndef MSP_GL_FRAMEBUFFER_BACKEND_H_
2 #define MSP_GL_FRAMEBUFFER_BACKEND_H_
3
4 #include <string>
5 #include "frameformat.h"
6 #include "handles.h"
7
8 namespace Msp {
9 namespace GL {
10
11 class Device;
12 class Texture;
13
14 class VulkanFramebuffer: public NonCopyable
15 {
16         friend class VulkanCommands;
17         friend class VulkanPipelineState;
18
19 protected:
20         Device &device;
21         mutable VkFramebuffer handle = 0;
22         std::string debug_name;
23
24         VulkanFramebuffer(bool);
25         VulkanFramebuffer(VulkanFramebuffer &&);
26         ~VulkanFramebuffer();
27
28         bool is_format_supported(const FrameFormat &);
29         static void require_layered() { }
30
31         void update(unsigned) const;
32         void require_complete() const { }
33
34         void set_debug_name(const std::string &);
35         void set_vulkan_object_name() const;
36 };
37
38 using FramebufferBackend = VulkanFramebuffer;
39
40 } // namespace GL
41 } // namespace Msp
42
43 #endif