Respect GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS
authorIago Toral Quiroga <itoral@igalia.com>
Tue, 17 Oct 2017 07:58:57 +0000 (09:58 +0200)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Tue, 31 Oct 2017 08:50:01 +0000 (04:50 -0400)
commitc391f897495fcf7980e9c4679518107005d42120
tree177c5d329ca73b85e4344beb74f6b9c271a35be4
parentbb261137e8aeec327b26c32fdcab2f0653f1de71
Respect GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS

KHR-GL45.enhanced_layouts.xfb_override_qualifiers_with_api
generates shaders that capture XFB for varyings of all types.
For the cases of dmat4x3, dmat3x4 and dmat4, this requires
over 64 transform feedback components in total, which is larger
than the minimum value that implementations are required to
support for GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS,
which the OpenGL 4.6 spec sets in 64. For implementations that
support this minimum, the generated shaders are invalid and
expected to fail to link.

Check the required component size of the XFB for the generated
shaders and skip them if they exceed the implementation limit.
At worse, for implementations that only support the minimum
number of transform feedback components required by the spec
it would only skip the 3 largest types (out of 34 being tested).

Components: OpenGL
VK-GL-CTS issue: 776

Affects:
KHR-GL45.enhanced_layouts.xfb_override_qualifiers_with_api

Change-Id: I51c9da494f96a0746f74116f817d99afd070a9ee
external/openglcts/modules/gl/gl4cEnhancedLayoutsTests.cpp
external/openglcts/modules/gl/gl4cEnhancedLayoutsTests.hpp