12345678910111213141516171819202122232425 |
- #ifndef LAYERED_FRAMEBUFFER_H
- #define LAYERED_FRAMEBUFFER_H
- #include <GL/glew.h>
- class LayeredFramebuffer final {
- GLuint texture;
- GLuint buffer;
- public:
- LayeredFramebuffer(int width, int height, int depth);
- ~LayeredFramebuffer();
- LayeredFramebuffer(const LayeredFramebuffer&) = delete;
- LayeredFramebuffer(LayeredFramebuffer&&) = delete;
- LayeredFramebuffer& operator=(const LayeredFramebuffer&) = delete;
- LayeredFramebuffer& operator=(LayeredFramebuffer&&) = delete;
- void bindAndClear();
- void bindTextureTo(int unit) const;
- void bindLayer(int layer);
- bool hasError() const;
- };
- #endif
|