summaryrefslogtreecommitdiff
path: root/src/mesa/swrast/s_drawpix.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2001-05-16 20:27:12 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2001-05-16 20:27:12 +0000
commit47cf442c1164b6b406117fccfb8b564602741ee3 (patch)
treecd3e7c6147b0b19b091c38ad78785e8d18235ea3 /src/mesa/swrast/s_drawpix.c
parent441a4af435b46e1b475318fbaf4e80b774390cb0 (diff)
use DEFARRAY, etc macros to work around 32k data limit on Macs (Tom Goon)
Diffstat (limited to 'src/mesa/swrast/s_drawpix.c')
-rw-r--r--src/mesa/swrast/s_drawpix.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/src/mesa/swrast/s_drawpix.c b/src/mesa/swrast/s_drawpix.c
index e914eb7013..59b2d0294b 100644
--- a/src/mesa/swrast/s_drawpix.c
+++ b/src/mesa/swrast/s_drawpix.c
@@ -1,4 +1,4 @@
-/* $Id: s_drawpix.c,v 1.18 2001/05/15 21:30:27 brianp Exp $ */
+/* $Id: s_drawpix.c,v 1.19 2001/05/16 20:27:12 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -818,11 +818,18 @@ draw_rgba_pixels( GLcontext *ctx, GLint x, GLint y,
continue;
if (ctx->Texture._ReallyEnabled && ctx->Pixel.PixelTextureEnabled) {
- GLfloat s[MAX_WIDTH], t[MAX_WIDTH], r[MAX_WIDTH], q[MAX_WIDTH];
GLchan primary_rgba[MAX_WIDTH][4];
GLuint unit;
- /* XXX not sure how multitexture is supposed to work here */
+ 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);
+ /* 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++) {
@@ -834,6 +841,10 @@ draw_rgba_pixels( GLcontext *ctx, GLint x, GLint y,
rgba);
}
}
+ UNDEFARRAY(s); /* mac 32k limitation */
+ UNDEFARRAY(t);
+ UNDEFARRAY(r);
+ UNDEFARRAY(q);
}
if (quickDraw) {