summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/texparam.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/texparam.c')
-rw-r--r--src/mesa/main/texparam.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/mesa/main/texparam.c b/src/mesa/main/texparam.c
index 416792f0e99..4ce8c8593a9 100644
--- a/src/mesa/main/texparam.c
+++ b/src/mesa/main/texparam.c
@@ -551,8 +551,13 @@ _mesa_TexParameterf(GLenum target, GLenum pname, GLfloat param)
}
break;
default:
- /* this will generate an error if pname is illegal */
- need_update = set_tex_parameterf(ctx, texObj, pname, &param);
+ {
+ /* this will generate an error if pname is illegal */
+ GLfloat p[4];
+ p[0] = param;
+ p[1] = p[2] = p[3] = 0.0F;
+ need_update = set_tex_parameterf(ctx, texObj, pname, p);
+ }
}
if (ctx->Driver.TexParameter && need_update) {