kwin: Fix the blend function in the lanczos filter
The alpha values are pre-multiplied.
This commit is contained in:
parent
e59867dd92
commit
2cec03dede
1 changed files with 2 additions and 2 deletions
|
@ -208,7 +208,7 @@ void LanczosFilter::performPaint(EffectWindowImpl* w, int mask, QRegion region,
|
||||||
}
|
}
|
||||||
if (effects->compositingType() == OpenGL2Compositing) {
|
if (effects->compositingType() == OpenGL2Compositing) {
|
||||||
glEnable(GL_BLEND);
|
glEnable(GL_BLEND);
|
||||||
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
|
|
||||||
const qreal rgb = data.brightness() * data.opacity();
|
const qreal rgb = data.brightness() * data.opacity();
|
||||||
const qreal a = data.opacity();
|
const qreal a = data.opacity();
|
||||||
|
@ -344,7 +344,7 @@ void LanczosFilter::performPaint(EffectWindowImpl* w, int mask, QRegion region,
|
||||||
}
|
}
|
||||||
if (effects->compositingType() == OpenGL2Compositing) {
|
if (effects->compositingType() == OpenGL2Compositing) {
|
||||||
glEnable(GL_BLEND);
|
glEnable(GL_BLEND);
|
||||||
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
|
|
||||||
const qreal rgb = data.brightness() * data.opacity();
|
const qreal rgb = data.brightness() * data.opacity();
|
||||||
const qreal a = data.opacity();
|
const qreal a = data.opacity();
|
||||||
|
|
Loading…
Reference in a new issue