summaryrefslogtreecommitdiffstats
path: root/src/compiler/glsl/ir.h
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2016-06-14 14:38:04 -0700
committerIan Romanick <[email protected]>2016-07-05 16:58:27 -0700
commit3119871bd9558e5881466b70a4c366d2f83bba82 (patch)
treebadc9fd39f6832a0fbcd8ae973b42cd6d5d3067d /src/compiler/glsl/ir.h
parent73a6a4ce4975016d4f86d644b31d30bb6d3a38f8 (diff)
glsl: Pack integer and double varyings as flat even if interpolation mode is none
v2: Also update varying_matches::compute_packing_class(). Suggested by Timothy Arceri. Signed-off-by: Ian Romanick <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96358 Reviewed-by: Kenneth Graunke <[email protected]> Cc: "12.0" <[email protected]> Cc: Gregory Hainaut <[email protected]> Cc: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/compiler/glsl/ir.h')
-rw-r--r--src/compiler/glsl/ir.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/compiler/glsl/ir.h b/src/compiler/glsl/ir.h
index cd56a2a9f52..1325e3533fe 100644
--- a/src/compiler/glsl/ir.h
+++ b/src/compiler/glsl/ir.h
@@ -590,6 +590,13 @@ public:
return this->u.state_slots;
}
+ inline bool is_interpolation_flat() const
+ {
+ return this->data.interpolation == INTERP_QUALIFIER_FLAT ||
+ this->type->contains_integer() ||
+ this->type->contains_double();
+ }
+
inline bool is_name_ralloced() const
{
return this->name != ir_variable::tmp_name;