summaryrefslogtreecommitdiff
path: root/src/mesa/swrast/s_drawpix.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2002-01-10 16:54:28 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2002-01-10 16:54:28 +0000
commit9927f1978da8530416f699d084dda099720e43e6 (patch)
tree5ec35f60227bec8efa9ffe410f7984126b7adc66 /src/mesa/swrast/s_drawpix.c
parent2e99cbd9539cf686a45ffdfb9ec6c6a88e3aaa47 (diff)
Klaus's latest patches: change texcoord[3] to texcoord[4] everywhere
Diffstat (limited to 'src/mesa/swrast/s_drawpix.c')
-rw-r--r--src/mesa/swrast/s_drawpix.c34
1 files changed, 8 insertions, 26 deletions
diff --git a/src/mesa/swrast/s_drawpix.c b/src/mesa/swrast/s_drawpix.c
index 7f31c62941..b3a4a7886d 100644
--- a/src/mesa/swrast/s_drawpix.c
+++ b/src/mesa/swrast/s_drawpix.c
@@ -1,10 +1,10 @@
-/* $Id: s_drawpix.c,v 1.23 2001/12/17 04:54:35 brianp Exp $ */
+/* $Id: s_drawpix.c,v 1.24 2002/01/10 16:54:29 brianp Exp $ */
/*
* Mesa 3-D graphics library
- * Version: 3.5
+ * Version: 4.1
*
- * Copyright (C) 1999-2001 Brian Paul All Rights Reserved.
+ * Copyright (C) 1999-2002 Brian Paul All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -839,42 +839,24 @@ draw_rgba_pixels( GLcontext *ctx, GLint x, GLint y,
if (ctx->Texture._ReallyEnabled && ctx->Pixel.PixelTextureEnabled) {
GLchan primary_rgba[MAX_WIDTH][4];
GLuint unit;
- GLfloat texcoord[MAX_WIDTH][3];
- DEFARRAY(GLfloat, s, MAX_WIDTH); /* mac 32k limitation */
- DEFARRAY(GLfloat, t, MAX_WIDTH);
- DEFARRAY(GLfloat, r, MAX_WIDTH);
- DEFARRAY(GLfloat, q, MAX_WIDTH);
- CHECKARRAY(s, return); /* mac 32k limitation */
- CHECKARRAY(t, return);
- CHECKARRAY(r, return);
- CHECKARRAY(q, return);
+
+ DEFMARRAY(GLfloat, texcoord, MAX_WIDTH, 4);/* mac 32k limitation */
+ CHECKARRAY(texcoord, return); /* mac 32k limitation */
/* XXX not sure how multitexture is supposed to work here */
MEMCPY(primary_rgba, rgba, 4 * width * sizeof(GLchan));
for (unit = 0; unit < ctx->Const.MaxTextureUnits; unit++) {
if (ctx->Texture.Unit[unit]._ReallyEnabled) {
- GLint i;
_mesa_pixeltexgen(ctx, width, (const GLchan (*)[4]) rgba,
- s, t, r, q);
- /* this is an ugly work-around. s,t,r has to be
- copied to texcoords, because the functions need
- different input. */
- for (i=0; i<width; i++) {
- texcoord[i][0] = s[i],
- texcoord[i][1] = t[i],
- texcoord[i][2] = r[i];
- }
+ texcoord);
_old_swrast_texture_fragments( ctx, unit, width,
texcoord, NULL,
(CONST GLchan (*)[4]) primary_rgba,
rgba);
}
}
- UNDEFARRAY(s); /* mac 32k limitation */
- UNDEFARRAY(t);
- UNDEFARRAY(r);
- UNDEFARRAY(q);
+ UNDEFARRAY(texcoord); /* mac 32k limitation */
}
if (quickDraw) {