From 1e444c9960b18bcee5216a49db997b1c5ec14eca Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 15:08:01 -0800 Subject: swrast: Initialize tex_coords in handle_sample_op. --- src/mesa/swrast/s_atifragshader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa/swrast') diff --git a/src/mesa/swrast/s_atifragshader.c b/src/mesa/swrast/s_atifragshader.c index 5fefae6c42..e88ff19123 100644 --- a/src/mesa/swrast/s_atifragshader.c +++ b/src/mesa/swrast/s_atifragshader.c @@ -279,7 +279,7 @@ handle_sample_op(GLcontext * ctx, struct atifs_machine *machine, /* sample from unit idx using texinst->src as coords */ GLuint swizzle = texinst->swizzle; GLuint coord_source = texinst->src; - GLfloat tex_coords[4]; + GLfloat tex_coords[4] = { 0 }; if (coord_source >= GL_TEXTURE0_ARB && coord_source <= GL_TEXTURE7_ARB) { coord_source -= GL_TEXTURE0_ARB; -- cgit v1.2.3 From 555dc25c4c5a0991fb6846ccc263a195717512de Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 12 Dec 2009 23:47:32 -0800 Subject: swrast: Silence uninitialized variable warnings in s_triangle.c --- src/mesa/swrast/s_triangle.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/mesa/swrast') diff --git a/src/mesa/swrast/s_triangle.c b/src/mesa/swrast/s_triangle.c index 1ab0e19f92..a65b7b3e22 100644 --- a/src/mesa/swrast/s_triangle.c +++ b/src/mesa/swrast/s_triangle.c @@ -540,6 +540,9 @@ affine_span(GLcontext *ctx, SWspan *span, info.format = obj->Image[0][b]->_BaseFormat; \ info.filter = obj->MinFilter; \ info.envmode = unit->EnvMode; \ + info.er = 0; \ + info.eg = 0; \ + info.eb = 0; \ span.arrayMask |= SPAN_RGBA; \ \ if (info.envmode == GL_BLEND) { \ @@ -809,6 +812,9 @@ fast_persp_span(GLcontext *ctx, SWspan *span, info.format = obj->Image[0][b]->_BaseFormat; \ info.filter = obj->MinFilter; \ info.envmode = unit->EnvMode; \ + info.er = 0; \ + info.eg = 0; \ + info.eb = 0; \ \ if (info.envmode == GL_BLEND) { \ /* potential off-by-one error here? (1.0f -> 2048 -> 0) */ \ -- cgit v1.2.3