diff options
author | Kenneth Graunke <[email protected]> | 2014-09-01 02:17:41 -0700 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2014-10-15 17:04:52 -0700 |
commit | 465373535e277a3ccdf440d38f867a40ec352638 (patch) | |
tree | 9bb403b96c33290eb88b95fcb98a6244d04672d9 /src/mesa/drivers/dri | |
parent | fa212c6b985f494f5609ccca1c260a2aa39c684a (diff) |
i965/fs: Rename "length" to "components" in emit_mcs_fetch().
This is slightly clearer. Based on a patch by Connor Abbott.
Signed-off-by: Kenneth Graunke <[email protected]>
Reviewed-by: Chris Forbes <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp b/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp index ad348f7e0cf..7ced1239c97 100644 --- a/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp @@ -1811,24 +1811,24 @@ fs_reg fs_visitor::emit_mcs_fetch(ir_texture *ir, fs_reg coordinate, fs_reg sampler) { int reg_width = dispatch_width / 8; - int length = ir->coordinate->type->vector_elements; - fs_reg payload = fs_reg(GRF, virtual_grf_alloc(length * reg_width), + int components = ir->coordinate->type->vector_elements; + fs_reg payload = fs_reg(GRF, virtual_grf_alloc(components * reg_width), BRW_REGISTER_TYPE_F); fs_reg dest = fs_reg(this, glsl_type::uvec4_type); - fs_reg *sources = ralloc_array(mem_ctx, fs_reg, length); + fs_reg *sources = ralloc_array(mem_ctx, fs_reg, components); /* parameters are: u, v, r; missing parameters are treated as zero */ - for (int i = 0; i < length; i++) { + for (int i = 0; i < components; i++) { sources[i] = fs_reg(this, glsl_type::float_type); emit(MOV(retype(sources[i], BRW_REGISTER_TYPE_D), coordinate)); coordinate = offset(coordinate, 1); } - emit(LOAD_PAYLOAD(payload, sources, length)); + emit(LOAD_PAYLOAD(payload, sources, components)); fs_inst *inst = emit(SHADER_OPCODE_TXF_MCS, dest, payload, sampler); inst->base_mrf = -1; - inst->mlen = length * reg_width; + inst->mlen = components * reg_width; inst->header_present = false; inst->regs_written = 4 * reg_width; /* we only care about one reg of * response, but the sampler always |