D22153: blur: Disable sRGB when the framebuffer is linear

Vlad Zagorodniy noreply at phabricator.kde.org
Sat Jun 29 13:40:44 BST 2019


zzag added inline comments.

INLINE COMMENTS

> blur.cpp:133
> +        GLenum colorEncoding = GL_LINEAR;
> +        glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, GL_BACK_LEFT,
> +                                              GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING,

Do we need to check whether the default framebuffer object is bound?

> blur.cpp:137-138
> +
> +        if (colorEncoding == GL_SRGB)
> +            textureFormat = GL_SRGB8_ALPHA8;
> +    }

Coding style nitpick:  Use curly braces even when the body of a conditional statement contains only one line.

> blur.cpp:656
>  
> -    const bool isGLES = GLPlatform::instance()->isGLES();
> +    const bool useSRGB = m_renderTextures.first().internalFormat() == GL_SRGB8_ALPHA8;
>  

Do we have to worry about the looking glass effect and all other effects that render the scene to a texture?

REPOSITORY
  R108 KWin

REVISION DETAIL
  https://phabricator.kde.org/D22153

To: fredrik, #kwin
Cc: zzag, kwin, LeGast00n, sbergeron, jraleigh, fbampaloukas, GB_2, mkulinski, ragreen, jackyalcine, Pitel, iodelay, crozbo, bwowk, ZrenBot, ngraham, alexeymin, himcesjf, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kwin/attachments/20190629/2c9b1b3f/attachment-0001.html>


More information about the kwin mailing list