summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorIlia Mirkin <[email protected]>2014-07-09 02:27:36 -0400
committerIlia Mirkin <[email protected]>2014-07-09 12:40:07 -0400
commite924bb32f4ebf5d0a090c133ead2f9ee581c9a7a (patch)
tree49e0376371858c04e043d1d0232f2b66d3283a08 /src
parentc8011c1885003b79c9f0c6530e46ae6cb0e69575 (diff)
tgsi: properly parse indirect dimension references (e.g. for UBOs)
Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/auxiliary/tgsi/tgsi_text.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/tgsi/tgsi_text.c b/src/gallium/auxiliary/tgsi/tgsi_text.c
index 7e50d8d0ce3..e424d99702d 100644
--- a/src/gallium/auxiliary/tgsi/tgsi_text.c
+++ b/src/gallium/auxiliary/tgsi/tgsi_text.c
@@ -804,6 +804,13 @@ parse_src_operand(
src->Dimension.Indirect = 0;
src->Dimension.Dimension = 0;
src->Dimension.Index = bracket[0].index;
+ if (bracket[0].ind_file != TGSI_FILE_NULL) {
+ src->Dimension.Indirect = 1;
+ src->DimIndirect.File = bracket[0].ind_file;
+ src->DimIndirect.Index = bracket[0].ind_index;
+ src->DimIndirect.Swizzle = bracket[0].ind_comp;
+ src->DimIndirect.ArrayID = bracket[0].ind_array;
+ }
bracket[0] = bracket[1];
}
src->Register.Index = bracket[0].index;