return STOP;
}
-class EnableBlendCase : public TestCase
-{
-public:
- EnableBlendCase (Context& context, const char* name, const char* desc, QueryType verifierType);
-
- void init (void);
-private:
- IterateResult iterate (void);
-
- const QueryType m_verifierType;
-};
-
-EnableBlendCase::EnableBlendCase (Context& context, const char* name, const char* desc, QueryType verifierType)
- : TestCase (context, name, desc)
- , m_verifierType (verifierType)
-{
-}
-
-void EnableBlendCase::init (void)
-{
- isExtensionSupported(m_context, "GL_EXT_draw_buffers_indexed");
-}
-
-EnableBlendCase::IterateResult EnableBlendCase::iterate (void)
-{
- glu::CallLogWrapper gl (m_context.getRenderContext().getFunctions(), m_testCtx.getLog());
- tcu::ResultCollector result (m_testCtx.getLog(), " // ERROR: ");
- deInt32 maxDrawBuffers = 0;
-
- gl.enableLogging(true);
-
- gl.glGetIntegerv(GL_MAX_DRAW_BUFFERS, &maxDrawBuffers);
- GLU_EXPECT_NO_ERROR(gl.glGetError(), "glGetIntegerv");
-
- {
- const tcu::ScopedLogSection section(m_testCtx.getLog(), "Initial", "Initial value");
-
- for (int ndx = 0; ndx < maxDrawBuffers; ++ndx)
- verifyStateIndexedBoolean(result, gl, GL_BLEND, ndx, false, m_verifierType);
- }
- {
- const tcu::ScopedLogSection superSection (m_testCtx.getLog(), "AfterSettingCommon", "After setting common");
-
- gl.glEnable(GL_BLEND);
-
- for (int ndx = 0; ndx < maxDrawBuffers; ++ndx)
- verifyStateIndexedBoolean(result, gl, GL_BLEND, ndx, true, m_verifierType);
-
- }
- {
- const tcu::ScopedLogSection superSection (m_testCtx.getLog(), "AfterSettingIndexed", "After setting indexed");
-
- for (int ndx = 0; ndx < maxDrawBuffers; ++ndx)
- {
- if (ndx % 2 == 0)
- gl.glEnablei(GL_BLEND, ndx);
- else
- gl.glDisablei(GL_BLEND, ndx);
- }
-
- for (int ndx = 0; ndx < maxDrawBuffers; ++ndx)
- verifyStateIndexedBoolean(result, gl, GL_BLEND, ndx, (ndx % 2 == 0), m_verifierType);
- }
- {
- const tcu::ScopedLogSection superSection (m_testCtx.getLog(), "AfterResettingIndexedWithCommon", "After resetting indexed with common");
-
- for (int ndx = 0; ndx < maxDrawBuffers; ++ndx)
- {
- if (ndx % 2 == 0)
- gl.glEnablei(GL_BLEND, ndx);
- else
- gl.glDisablei(GL_BLEND, ndx);
- }
-
- gl.glEnable(GL_BLEND);
-
- for (int ndx = 0; ndx < maxDrawBuffers; ++ndx)
- verifyStateIndexedBoolean(result, gl, GL_BLEND, ndx, true, m_verifierType);
- }
-
- result.setTestContextResult(m_testCtx);
- return STOP;
-}
-
class ColorMaskCase : public TestCase
{
public: