From fc8d6d3ea142df74885e5d64bc89e677d9f393b6 Mon Sep 17 00:00:00 2001 From: Laszlo Agocs Date: Thu, 26 Sep 2019 09:38:56 +0200 Subject: rhi: gl: Fix not resetting color write bits when switching pipeline MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This was visible in the triquadcube test when enabling transparent window background: the cube on the left was rendered incorrectly because alpha was not written out due to not setting glColorMask() back to the defaults when switching to another pipeline. Change-Id: I7a8c94072e0b68a58fffcc8c1a200e3940dcad44 Reviewed-by: Christian Strømme --- src/gui/rhi/qrhigles2.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/gui/rhi') diff --git a/src/gui/rhi/qrhigles2.cpp b/src/gui/rhi/qrhigles2.cpp index 838c28efa2..cc5d41ea46 100644 --- a/src/gui/rhi/qrhigles2.cpp +++ b/src/gui/rhi/qrhigles2.cpp @@ -2258,6 +2258,7 @@ void QRhiGles2::executeBindGraphicsPipeline(QRhiGraphicsPipeline *ps) } } else { f->glDisable(GL_BLEND); + f->glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); } if (psD->m_depthTest) f->glEnable(GL_DEPTH_TEST); -- cgit v1.2.3