From ba17d2cffc8d6fdbcb884f16c243666e1d1148dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Ka=CC=88fer?= Date: Thu, 22 May 2014 15:17:26 +0200 Subject: [PATCH] no need to use nonpremultiplied alpha blending --- src/renderer/painter_composite.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/renderer/painter_composite.cpp b/src/renderer/painter_composite.cpp index 9ff5de108..af3fd8e32 100644 --- a/src/renderer/painter_composite.cpp +++ b/src/renderer/painter_composite.cpp @@ -8,11 +8,6 @@ void Painter::drawComposite(GLuint texture, const CompositeProperties &propertie // We're doing full-screen framebuffer blending, so no need to do stencil testing here. glDisable(GL_STENCIL_TEST); - // Normally, we're using premultiplied alpha, but the resulting image we've - // just drawn is non-premultiplied. That means when blending, we have to make - // sure that we account for that. - glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); - useProgram(compositeShader->program); compositeShader->setMatrix(nativeMatrix); @@ -32,7 +27,4 @@ void Painter::drawComposite(GLuint texture, const CompositeProperties &propertie // Reset back. glEnable(GL_STENCIL_TEST); - - // Reset back to use premultiplied alpha blending. - glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA); }