aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2015-01-09 20:01:13 -0800
committerJason Ekstrand <[email protected]>2015-01-15 07:20:24 -0800
commit4aa6162f6ecf96c7400c17c310eba0cfd0f5e083 (patch)
treebf3038964219161441349f7881224dc733a937fe /src/mesa/drivers
parentdcb1acdea00a8f2c29777ff4078832df9d5b40ce (diff)
nir/tex_instr: Add a nir_tex_src struct and dynamically allocate the src array
This solves a number of problems. First is the ability to change the number of sources that a texture instruction has. Second, it solves the delema that may occur if a texture instruction has more than 4 sources. Reviewed-by: Connor Abbott <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs_nir.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
index ee2f80e7f35..4c91a6edc44 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp
@@ -1625,8 +1625,8 @@ fs_visitor::nir_emit_texture(nir_tex_instr *instr)
fs_reg coordinate, shadow_comparitor, lod, lod2, sample_index, mcs, offset;
for (unsigned i = 0; i < instr->num_srcs; i++) {
- fs_reg src = get_nir_src(instr->src[i]);
- switch (instr->src_type[i]) {
+ fs_reg src = get_nir_src(instr->src[i].src);
+ switch (instr->src[i].src_type) {
case nir_tex_src_bias:
lod = retype(src, BRW_REGISTER_TYPE_F);
break;