From 1ac924a77d9bed20efd0241c6712043e07d9b268 Mon Sep 17 00:00:00 2001 From: Ian Romanick Date: Thu, 23 Oct 2014 09:20:26 -0700 Subject: [PATCH] ff_fragment_shader: Silence unused parameter warning in smear Just remove the parameter. Silences: ../../src/mesa/main/ff_fragment_shader.cpp:668:1: warning: unused parameter 'p' [-Wunused-parameter] Signed-off-by: Ian Romanick Reviewed-by: Brian Paul Reviewed-by: Matt Turner Reviewed-by: Kenneth Graunke --- src/mesa/main/ff_fragment_shader.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/mesa/main/ff_fragment_shader.cpp b/src/mesa/main/ff_fragment_shader.cpp index 9bb706cc549..e31a14516c4 100644 --- a/src/mesa/main/ff_fragment_shader.cpp +++ b/src/mesa/main/ff_fragment_shader.cpp @@ -665,7 +665,7 @@ static GLboolean args_match( const struct state_key *key, GLuint unit ) } static ir_rvalue * -smear(texenv_fragment_program *p, ir_rvalue *val) +smear(ir_rvalue *val) { if (!val->type->is_scalar()) return val; @@ -722,7 +722,7 @@ emit_combine(texenv_fragment_program *p, tmp1 = mul(src[1], new(p->mem_ctx) ir_constant(2.0f)); tmp1 = add(tmp1, new(p->mem_ctx) ir_constant(-1.0f)); - return dot(swizzle_xyz(smear(p, tmp0)), swizzle_xyz(smear(p, tmp1))); + return dot(swizzle_xyz(smear(tmp0)), swizzle_xyz(smear(tmp1))); } case MODE_MODULATE_ADD_ATI: return add(mul(src[0], src[2]), src[1]); @@ -804,7 +804,7 @@ emit_texenv(texenv_fragment_program *p, GLuint unit) key->unit[unit].NumArgsRGB, key->unit[unit].ModeRGB, key->unit[unit].OptRGB); - val = smear(p, val); + val = smear(val); if (rgb_saturate) val = saturate(val); @@ -816,7 +816,7 @@ emit_texenv(texenv_fragment_program *p, GLuint unit) key->unit[unit].NumArgsRGB, key->unit[unit].ModeRGB, key->unit[unit].OptRGB); - val = smear(p, val); + val = smear(val); if (rgb_saturate) val = saturate(val); p->emit(assign(temp_var, val)); @@ -829,7 +829,7 @@ emit_texenv(texenv_fragment_program *p, GLuint unit) key->unit[unit].NumArgsRGB, key->unit[unit].ModeRGB, key->unit[unit].OptRGB); - val = swizzle_xyz(smear(p, val)); + val = swizzle_xyz(smear(val)); if (rgb_saturate) val = saturate(val); p->emit(assign(temp_var, val, WRITEMASK_XYZ)); @@ -838,7 +838,7 @@ emit_texenv(texenv_fragment_program *p, GLuint unit) key->unit[unit].NumArgsA, key->unit[unit].ModeA, key->unit[unit].OptA); - val = swizzle_w(smear(p, val)); + val = swizzle_w(smear(val)); if (alpha_saturate) val = saturate(val); p->emit(assign(temp_var, val, WRITEMASK_W)); -- 2.30.2