From f0dd493b71fa4328065fa6775b2c37b4ac6e5814 Mon Sep 17 00:00:00 2001 From: Mark Adams Date: Wed, 13 Sep 2017 14:54:40 -0400 Subject: [PATCH] Limit max renderbuffer size to avoid too-large allocations This brings the ES2 version of this test in-line with the ES3 version in order to avoid hitting address-space limitations with very large max sizes in 32-bit mode. VK-GL-CTS issue: 687 Affects: dEQP-GLES2.functional.state_query.rbo.renderbuffer_size Change-Id: Id3a0be7e8e2e6aaf3dcb6d9cd2b1c4a9a19d4baf --- modules/gles2/functional/es2fRboStateQueryTests.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/modules/gles2/functional/es2fRboStateQueryTests.cpp b/modules/gles2/functional/es2fRboStateQueryTests.cpp index b49bbf5..f5dc50c 100644 --- a/modules/gles2/functional/es2fRboStateQueryTests.cpp +++ b/modules/gles2/functional/es2fRboStateQueryTests.cpp @@ -122,15 +122,11 @@ public: checkRenderbufferParam(m_testCtx, *this, GL_RENDERBUFFER_HEIGHT, 0); expectError(GL_NO_ERROR); - int maxRenderbufferSize = 1; - glGetIntegerv(GL_MAX_RENDERBUFFER_SIZE, &maxRenderbufferSize); - expectError(GL_NO_ERROR); - const int numIterations = 30; for (int i = 0; i < numIterations; ++i) { - const GLint w = rnd.getInt(0, maxRenderbufferSize); - const GLint h = rnd.getInt(0, maxRenderbufferSize); + const GLint w = rnd.getInt(0, 128); + const GLint h = rnd.getInt(0, 128); glRenderbufferStorage(GL_RENDERBUFFER, GL_RGBA4, w, h); expectError(GL_NO_ERROR); -- 2.7.4