[effects/screenedge] Use correct blend function
Summary: Glow textures already have the red, green, and blue channels premultiplied by the alpha component (because of QImage), thus we can't use GL_SRC_ALPHA for sfactor in glBlendFunc. BUG: 403570 Test Plan: Before: {F6592391} After: {F6592392} Reviewers: #kwin, davidedmundson Reviewed By: #kwin, davidedmundson Subscribers: kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D18803
This commit is contained in:
parent
54e46dbd9f
commit
bdddf4daf2
1 changed files with 1 additions and 1 deletions
|
@ -102,7 +102,7 @@ void ScreenEdgeEffect::paintScreen(int mask, QRegion region, ScreenPaintData &da
|
||||||
if (effects->isOpenGLCompositing()) {
|
if (effects->isOpenGLCompositing()) {
|
||||||
GLTexture *texture = (*it)->texture.data();
|
GLTexture *texture = (*it)->texture.data();
|
||||||
glEnable(GL_BLEND);
|
glEnable(GL_BLEND);
|
||||||
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
texture->bind();
|
texture->bind();
|
||||||
ShaderBinder binder(ShaderTrait::MapTexture | ShaderTrait::Modulate);
|
ShaderBinder binder(ShaderTrait::MapTexture | ShaderTrait::Modulate);
|
||||||
const QVector4D constant(opacity, opacity, opacity, opacity);
|
const QVector4D constant(opacity, opacity, opacity, opacity);
|
||||||
|
|
Loading…
Reference in a new issue