hyprlock/src/renderer/Framebuffer.hpp

24 lines
455 B
C++
Raw Normal View History

2024-02-21 23:19:01 +01:00
#pragma once
#include "../helpers/Vector2D.hpp"
#include <GLES3/gl32.h>
#include "Texture.hpp"
class CFramebuffer {
public:
~CFramebuffer();
2024-03-05 21:24:11 +01:00
bool alloc(int w, int h, bool highres = false);
2024-02-21 23:19:01 +01:00
void addStencil();
void bind() const;
void release();
void reset();
bool isAllocated();
Vector2D m_vSize;
CTexture m_cTex;
GLuint m_iFb = -1;
CTexture* m_pStencilTex = nullptr;
};