]> git.tdb.fi Git - libs/gl.git/blob - source/core/texture2dmultisample.h
Use default member initializers for simple types
[libs/gl.git] / source / core / texture2dmultisample.h
1 #ifndef MSP_GL_TEXTURE2DMULTISAMPLE_H_
2 #define MSP_GL_TEXTURE2DMULTISAMPLE_H_
3
4 #include "texture2dmultisample_backend.h"
5
6 namespace Msp {
7 namespace GL {
8
9 class Texture2DMultisample: public Texture2DMultisampleBackend
10 {
11         friend Texture2DMultisampleBackend;
12
13 private:
14         unsigned width = 0;
15         unsigned height = 0;
16         unsigned samples = 0;
17
18 public:
19         void storage(PixelFormat fmt, unsigned wd, unsigned ht, unsigned sm);
20
21         virtual void image(const Graphics::Image &, unsigned = 0);
22
23         unsigned get_width() const { return width; }
24         unsigned get_height() const { return height; }
25         unsigned get_samples() const { return samples; }
26
27         virtual AsyncLoader *load(IO::Seekable &, const Resources * = 0) { return 0; }
28         virtual std::uint64_t get_data_size() const;
29         virtual void unload() { }
30 };
31
32 } // namespace GL
33 } // namespace Msp
34
35 #endif