Enable sRGB framebuffer immediately on GL output window

This commit is contained in:
baldurk
2020-11-26 10:26:37 +00:00
parent 3f394aa5df
commit 593a903cf1
+3 -3
View File
@@ -100,6 +100,9 @@ void GLReplay::InitOutputWindow(OutputWindow &outwin)
drv.glGenFramebuffers(1, &outwin.BlitData.readFBO);
drv.glBindFramebuffer(eGL_READ_FRAMEBUFFER, outwin.BlitData.readFBO);
drv.glReadBuffer(eGL_COLOR_ATTACHMENT0);
if(HasExt[EXT_framebuffer_sRGB])
drv.glEnable(eGL_FRAMEBUFFER_SRGB);
}
bool GLReplay::CheckResizeOutputWindow(uint64_t id)
@@ -210,9 +213,6 @@ void GLReplay::FlipOutputWindow(uint64_t id)
outw.BlitData.backbuffer, 0);
drv.glReadBuffer(eGL_COLOR_ATTACHMENT0);
if(HasExt[EXT_framebuffer_sRGB])
drv.glEnable(eGL_FRAMEBUFFER_SRGB);
drv.glBlitFramebuffer(0, 0, outw.width, outw.height, 0, 0, outw.width, outw.height,
GL_COLOR_BUFFER_BIT, eGL_NEAREST);