glsl/linker: Allow fragment output overlap for gl_LastFragData.
authorFrancisco Jerez <currojerez@riseup.net>
Thu, 14 Jul 2016 19:57:14 +0000 (12:57 -0700)
committerFrancisco Jerez <currojerez@riseup.net>
Wed, 24 Aug 2016 20:28:31 +0000 (13:28 -0700)
gl_LastFragData overlaps gl_FragData by definition.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/compiler/glsl/linker.cpp

index a1a65ef627090dc03c1cd4fc699ad05b2275c79d..4b404fff350768d0ab64b5cca984e1817381468f 100644 (file)
@@ -2673,6 +2673,9 @@ assign_attribute_or_color_locations(void *mem_ctx,
          }
       }
 
+      if (strcmp(var->name, "gl_LastFragData") == 0)
+         continue;
+
       /* From GL4.5 core spec, section 15.2 (Shader Execution):
        *
        *     "Output binding assignments will cause LinkProgram to fail: