From 7c9be01c568d8e222db20085611815ada0db515a Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Thu, 12 Jul 2018 09:55:35 +0200 Subject: [PATCH] shaders: include prefix for samplepos and tesscoord Otherwise, we risk missing stuff like negation modifiers. Fixes the following dEQP failures for me: - dEQP-GLES31.functional.tessellation.common_edge.quads_equal_spacing - dEQP-GLES31.functional.tessellation.common_edge.quads_fractional_odd_spacing - dEQP-GLES31.functional.tessellation.common_edge.quads_fractional_even_spacing Signed-off-by: Erik Faye-Lund --- src/vrend_shader.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vrend_shader.c b/src/vrend_shader.c index 8e6b72d..15d7735 100644 --- a/src/vrend_shader.c +++ b/src/vrend_shader.c @@ -2648,7 +2648,8 @@ get_source_info(struct dump_ctx *ctx, ctx->system_values[j].glsl_name, src->Register.SwizzleW); } else if (ctx->system_values[j].name == TGSI_SEMANTIC_SAMPLEPOS || ctx->system_values[j].name == TGSI_SEMANTIC_TESSCOORD) { - snprintf(srcs[i], 255, "vec4(%s.%c, %s.%c, %s.%c, %s.%c)", + snprintf(srcs[i], 255, "%s(vec4(%s.%c, %s.%c, %s.%c, %s.%c))", + prefix, ctx->system_values[j].glsl_name, get_swiz_char(src->Register.SwizzleX), ctx->system_values[j].glsl_name, get_swiz_char(src->Register.SwizzleY), ctx->system_values[j].glsl_name, get_swiz_char(src->Register.SwizzleZ),