mirror of
https://github.com/hyprwm/Hyprland
synced 2024-12-22 20:49:49 +01:00
renderbuffer: ensure framebuffer gets deleted (#7363)
after commit 4b4971c
it uses m_iFbAllocated and deletes if upon calling
release() but Renderbuffer generates directly on m_iFb without calling
alloc() meaning it wont be deleted on release(), set m_iFbAllocated to
true after generating the buffer.
This commit is contained in:
parent
682b30fba8
commit
1840a907a8
1 changed files with 2 additions and 1 deletions
|
@ -35,7 +35,8 @@ CRenderbuffer::CRenderbuffer(SP<Aquamarine::IBuffer> buffer, uint32_t format) :
|
|||
glBindRenderbuffer(GL_RENDERBUFFER, 0);
|
||||
|
||||
glGenFramebuffers(1, &m_sFramebuffer.m_iFb);
|
||||
m_sFramebuffer.m_vSize = buffer->size;
|
||||
m_sFramebuffer.m_iFbAllocated = true;
|
||||
m_sFramebuffer.m_vSize = buffer->size;
|
||||
m_sFramebuffer.bind();
|
||||
glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_RENDERBUFFER, m_iRBO);
|
||||
|
||||
|
|
Loading…
Reference in a new issue