diff options
author | Ilia Mirkin <[email protected]> | 2015-12-13 03:23:13 -0500 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2015-12-13 11:35:28 -0500 |
commit | eca8f38dcffb700fdfe413a707d524e6a84bd453 (patch) | |
tree | 7fc80c1bbf10d30b4505d5addb88244d064d7f60 /src/glsl/linker.cpp | |
parent | 839793680f99b8387bee9489733d5071c10f3ace (diff) |
glsl: assign varying locations to tess shaders when doing SSO
GRID Autosport uses SSO shaders. When a tessellation evaluation shader
is passed through this, it triggers assertion failures down the line
with unassigned varying locations. Make sure to do this when the first
shader in the pipeline is not a vertex shader.
Signed-off-by: Ilia Mirkin <[email protected]>
Reviewed-by: Timothy Arceri <[email protected]>
Cc: "11.0 11.1" <[email protected]>
Diffstat (limited to 'src/glsl/linker.cpp')
-rw-r--r-- | src/glsl/linker.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index a87bbb2b994..b39c7f5d3ab 100644 --- a/src/glsl/linker.cpp +++ b/src/glsl/linker.cpp @@ -4423,13 +4423,13 @@ link_shaders(struct gl_context *ctx, struct gl_shader_program *prog) if (first < MESA_SHADER_FRAGMENT) { gl_shader *const sh = prog->_LinkedShaders[last]; - if (first == MESA_SHADER_GEOMETRY) { + if (first != MESA_SHADER_VERTEX) { /* There was no vertex shader, but we still have to assign varying - * locations for use by geometry shader inputs in SSO. + * locations for use by tessellation/geometry shader inputs in SSO. * * If the shader is not separable (i.e., prog->SeparateShader is - * false), linking will have already failed when first is - * MESA_SHADER_GEOMETRY. + * false), linking will have already failed when first is not + * MESA_SHADER_VERTEX. */ if (!assign_varying_locations(ctx, mem_ctx, prog, NULL, prog->_LinkedShaders[first], |