summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2011-08-05 19:38:44 -0700
committerEric Anholt <[email protected]>2011-08-16 13:04:42 -0700
commit8e947c2546c25c0dfa93b538e54113af1bf582df (patch)
tree2011e2d8b7528c4edf405934835534d55b6dd601
parent814a9bef30beda427e8fbf6f3b8abb6a45f0e2e4 (diff)
i965/vs: Fix the types of array/struct dereferences.
Fixes glsl-vs-arrays-3.
-rw-r--r--src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
index 734e2514536..b6f3cbc265f 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
@@ -1198,6 +1198,7 @@ vec4_visitor::visit(ir_dereference_array *ir)
src.swizzle = swizzle_for_size(ir->type->vector_elements);
else
src.swizzle = BRW_SWIZZLE_NOOP;
+ src.type = brw_type_for_base_type(ir->type);
this->result = src;
}
@@ -1222,6 +1223,7 @@ vec4_visitor::visit(ir_dereference_record *ir)
this->result.swizzle = swizzle_for_size(ir->type->vector_elements);
else
this->result.swizzle = BRW_SWIZZLE_NOOP;
+ this->result.type = brw_type_for_base_type(ir->type);
this->result.reg_offset += offset;
}