diff options
author | Dave Airlie <[email protected]> | 2016-04-26 09:48:46 +1000 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2016-04-27 08:26:53 +1000 |
commit | 912ed84f83381330f0d616678878935cd2366293 (patch) | |
tree | 85168c308604567b63518e07bf275d1c223e29ee /src/gallium/auxiliary/tgsi | |
parent | 9013d9267ce11efc9b841816630b34cbe8820d1d (diff) |
tgsi: move to using vector for system values.
For compute support some of the system values are .xyz types,
so move to using a vector instead of a single channel.
[airlied: squash swizzle fix from compute series].
Reviewed-by: Brian Paul <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/tgsi')
-rw-r--r-- | src/gallium/auxiliary/tgsi/tgsi_exec.c | 2 | ||||
-rw-r--r-- | src/gallium/auxiliary/tgsi/tgsi_exec.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/tgsi/tgsi_exec.c b/src/gallium/auxiliary/tgsi/tgsi_exec.c index e8bb1036420..f6b08bc8ee8 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_exec.c +++ b/src/gallium/auxiliary/tgsi/tgsi_exec.c @@ -1282,7 +1282,7 @@ fetch_src_file_channel(const struct tgsi_exec_machine *mach, * gl_FragCoord, for example, in a sys value register. */ for (i = 0; i < TGSI_QUAD_SIZE; i++) { - chan->u[i] = mach->SystemValue[index->i[i]].u[i]; + chan->u[i] = mach->SystemValue[index->i[i]].xyzw[swizzle].u[i]; } break; diff --git a/src/gallium/auxiliary/tgsi/tgsi_exec.h b/src/gallium/auxiliary/tgsi/tgsi_exec.h index 5e554d584cc..b12f7bed9b8 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_exec.h +++ b/src/gallium/auxiliary/tgsi/tgsi_exec.h @@ -356,7 +356,7 @@ struct tgsi_exec_machine /* System values */ unsigned SysSemanticToIndex[TGSI_SEMANTIC_COUNT]; - union tgsi_exec_channel SystemValue[TGSI_MAX_MISC_INPUTS]; + struct tgsi_exec_vector SystemValue[TGSI_MAX_MISC_INPUTS]; struct tgsi_exec_vector *Addrs; struct tgsi_exec_vector *Predicates; |