DiligentCore icon indicating copy to clipboard operation
DiligentCore copied to clipboard

Properly handle non-sRGB default framebuffer in OpenGL backend

Open TheMostDiligent opened this issue 4 years ago • 3 comments

Right now GL_FRAMEBUFFER_SRGB is set once during the engine initialization. As a result, this is always enabled for default framebuffer even when its format is not SRGB

TheMostDiligent avatar Mar 16 '20 05:03 TheMostDiligent

OpenGL is a mess. GL_FRAMEBUFFER_SRGB only affects rendering to SRGB framebuffers and enables linear->sRGB conversion when writing pixels to the framebuffer. This should always be enabled to be consistent with other backends.

TheMostDiligent avatar Mar 16 '20 15:03 TheMostDiligent

This needs to be done for default framebuffer

TheMostDiligent avatar Mar 16 '20 16:03 TheMostDiligent

You may want to update the Label as well.

julianxhokaxhiu avatar Mar 16 '20 17:03 julianxhokaxhiu