summaryrefslogtreecommitdiffstats
path: root/src/compiler/glsl/lower_packed_varyings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/glsl/lower_packed_varyings.cpp')
-rw-r--r--src/compiler/glsl/lower_packed_varyings.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/compiler/glsl/lower_packed_varyings.cpp b/src/compiler/glsl/lower_packed_varyings.cpp
index 13f7e5b52da..b1a3b49b1d5 100644
--- a/src/compiler/glsl/lower_packed_varyings.cpp
+++ b/src/compiler/glsl/lower_packed_varyings.cpp
@@ -742,10 +742,11 @@ lower_packed_varyings_visitor::get_packed_varying_deref(
bool
lower_packed_varyings_visitor::needs_lowering(ir_variable *var)
{
- /* Things composed of vec4's and varyings with explicitly assigned
- * locations don't need lowering. Everything else does.
+ /* Things composed of vec4's, varyings with explicitly assigned
+ * locations or varyings marked as must_be_shader_input (which might be used
+ * by interpolateAt* functions) shouldn't be lowered. Everything else can be.
*/
- if (var->data.explicit_location)
+ if (var->data.explicit_location || var->data.must_be_shader_input)
return false;
/* Override disable_varying_packing if the var is only used by transform