Non-zero stream outputs can't be used in fragment shaders.
authorJuan A. Suarez Romero <jasuarez@igalia.com>
Thu, 6 Jul 2017 09:19:56 +0000 (11:19 +0200)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Sun, 16 Jul 2017 12:53:49 +0000 (08:53 -0400)
According to ARB_gpu_shader5 spec, "Geometry Shader Vertex Streams"
section:

    "The primitives emitted to all vertex streams are passed to the transform
    feedback stage to be captured and written to buffer objects in the manner
    specified by the transform feedback state.  The primitives emitted to all
    streams but stream zero are discarded after transform feedback.
    Primitives emitted to stream zero are passed to subsequent pipeline stages
    for clipping, rasterization, and subsequent fragment processing."

Thus, it is an error trying to use a GS output as FS input that was
emitted through non-zero stream.

Affects:
KHR-GL45.enhanced_layouts.xfb_vertex_streams

Components: OpenGL

VK-GL-CTS issue: 557

Change-Id: I008c929b600905b1f3eb27a05753c8c75bf82ac5

external/openglcts/modules/gl/gl4cEnhancedLayoutsTests.cpp

index d822e65..2ba0663 100644 (file)
@@ -23065,7 +23065,7 @@ void XFBVertexStreamsTest::getShaderBody(GLuint /* test_case_index */, Utils::Sh
                                                          "    EmitStreamVertex(2);\n"
                                                          "    EndStreamPrimitive(2);\n";
 
-       static const GLchar* fs = "    fs_out = gohan + goku + goten + picolo + vegeta + bulma;\n";
+       static const GLchar* fs = "    fs_out = gohan + goku + goten;\n";
 
        const GLchar* assignments = "";
        switch (stage)
@@ -23117,9 +23117,6 @@ void XFBVertexStreamsTest::getShaderInterface(GLuint /* test_case_index */, Util
        static const GLchar* fs = "in vec4 goku;\n"
                                                          "in vec4 gohan;\n"
                                                          "in vec4 goten;\n"
-                                                         "in vec4 picolo;\n"
-                                                         "in vec4 vegeta;\n"
-                                                         "in vec4 bulma;\n"
                                                          "\n"
                                                          "out vec4 fs_out;\n";