From: Jarkko Pöyry Date: Thu, 5 Feb 2015 20:39:16 +0000 (-0800) Subject: Disable coherent blending in non-coherent blend tests. X-Git-Tag: upstream/0.1.0~1972^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=57c60b3189ce3ac3e738d715313313cd140ef87c;p=platform%2Fupstream%2FVK-GL-CTS.git Disable coherent blending in non-coherent blend tests. Bug: 19283100 Change-Id: Idd464d9e107d4390bb009cab5325f998816b4927 --- diff --git a/modules/gles31/functional/es31fAdvancedBlendTests.cpp b/modules/gles31/functional/es31fAdvancedBlendTests.cpp index aed9395..f005f61 100644 --- a/modules/gles31/functional/es31fAdvancedBlendTests.cpp +++ b/modules/gles31/functional/es31fAdvancedBlendTests.cpp @@ -104,6 +104,8 @@ private: const RenderTargetType m_rtType; const int m_numIters; + bool m_coherentExtensionSupported; + deUint32 m_colorRbo; deUint32 m_fbo; @@ -224,6 +226,8 @@ void AdvancedBlendCase::init (void) DE_ASSERT(!m_referenceRenderer); DE_ASSERT(!m_refColorBuffer); + m_coherentExtensionSupported = m_context.getContextInfo().isExtensionSupported("GL_KHR_blend_equation_advanced_coherent"); + m_program = new glu::ShaderProgram(m_context.getRenderContext(), getBlendProgramSrc(sglr::rr_util::mapGLBlendEquationAdvanced(m_blendMode))); m_testCtx.getLog() << *m_program; @@ -414,8 +418,12 @@ AdvancedBlendCase::IterateResult AdvancedBlendCase::iterate (void) gl.useProgram(program); gl.viewport(viewportX, viewportY, m_viewportWidth, m_viewportHeight); gl.blendEquation(m_blendMode); + + // \note coherent extension enables GL_BLEND_ADVANCED_COHERENT_KHR by default if (m_coherentBlending) gl.enable(GL_BLEND_ADVANCED_COHERENT_KHR); + else if (m_coherentExtensionSupported) + gl.disable(GL_BLEND_ADVANCED_COHERENT_KHR); GLU_EXPECT_NO_ERROR(gl.getError(), "Failed to set render state");