This implements waiver from bug 13788 for texture_barrier tests.
authorCygan, Slawomir <slawomir.cygan@intel.com>
Tue, 18 Jul 2017 11:27:12 +0000 (13:27 +0200)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 11 Aug 2017 15:48:04 +0000 (11:48 -0400)
If the waiver is enabled, the surface width is reduced to 16382 to avoid
rasterization problems.

As previously the waiver was GTF-only, this change moves it to shared
openglcts / kc-cts file.

Affects:
KHR-GL45.texture_barrier.*
KHR-GL45.texture_barrier_ARB.*

Component: OpenGL

VK-GL-CTS issue: 580

Change-Id: I1149f5a8810de0a5f00ecd4b6b8252511346f106

external/fetch_kc_cts.py
external/openglcts/modules/common/CMakeLists.txt
external/openglcts/modules/common/glcWaiver.hpp [new file with mode: 0644]
external/openglcts/modules/gl/gl4cTextureBarrierTests.cpp

index 4645adc..dc5bb0f 100644 (file)
@@ -32,7 +32,7 @@ sys.path.append(os.path.join(os.path.dirname(__file__), "..", "scripts"))
 from build.common import *
 
 EXTERNAL_DIR   = os.path.realpath(os.path.normpath(os.path.dirname(__file__)))
-SHA1 = "7a4b4b4649d0a665e798ff9179f771d72c264bc0"
+SHA1 = "2cdb19e34748b7febf7c1a900958bf88ab6b0485"
 
 PACKAGES = [
        GitRepo(
index f1953ab..77fd8b1 100644 (file)
@@ -86,6 +86,7 @@ set(GLCTS_COMMON_SRCS
        glcExtTokens.hpp
        glcLimitTest.inl
        glcLimitTest.hpp
+       glcWaiver.hpp
        )
 
 set(GLCTS_COMMON_LIBS
diff --git a/external/openglcts/modules/common/glcWaiver.hpp b/external/openglcts/modules/common/glcWaiver.hpp
new file mode 100644 (file)
index 0000000..d2a4673
--- /dev/null
@@ -0,0 +1,38 @@
+#ifndef _GLCWAIVER_HPP
+#define _GLCWAIVER_HPP
+/*-------------------------------------------------------------------------
+ * OpenGL Conformance Test Suite
+ * -----------------------------
+ *
+ * Copyright (c) 2014-2017 The Khronos Group Inc.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */ /*!
+ * \file
+ * \brief
+ */ /*-------------------------------------------------------------------*/
+
+
+/* Bug 13788 - Waiver request for bug related to
+   rendering last 2 columns of pixels in 16K wide textures / render buffers
+
+   This define disables testing of rendering of primitives that fit 2x2 of
+   the lower left corner of the framebuffer, if framebuffer's width
+   is greater than 16383.
+
+   Disabled by default
+*/
+// #define WAIVER_WITH_BUG_13788
+
+#endif // _GLCWAIVER_HPP
index 45567fb..8901133 100644 (file)
@@ -45,6 +45,8 @@
 #include "glw.h"
 #include "glwFunctions.hpp"
 
+#include "glcWaiver.hpp"
+
 namespace gl4cts
 {
 
@@ -150,6 +152,10 @@ protected:
                m_width                                                           = renderTarget.getWidth();
                m_height                                                          = renderTarget.getHeight();
 
+#ifdef WAIVER_WITH_BUG_13788
+               m_width = m_width >= 16383 ? 16382 : m_width;
+#endif
+
                const glw::Functions& gl = m_context.getRenderContext().getFunctions();
 
                // Create textures