diff options
author | Brian Paul <brian.paul@tungstengraphics.com> | 2002-03-14 22:09:25 +0000 |
---|---|---|
committer | Brian Paul <brian.paul@tungstengraphics.com> | 2002-03-14 22:09:25 +0000 |
commit | 612fc012934d9ec61972c3cfd914923937339611 (patch) | |
tree | 13011ada8b5e3eda8e5b4123285236c9d57ba2c7 /src | |
parent | d488af5b34e390a9b81dac96053bd45f34ffffff (diff) |
fixed pointer arithmetic error in glCopyPixels
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/swrast/s_copypix.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mesa/swrast/s_copypix.c b/src/mesa/swrast/s_copypix.c index 3dbbe6e7af..5f8c35daaa 100644 --- a/src/mesa/swrast/s_copypix.c +++ b/src/mesa/swrast/s_copypix.c @@ -1,4 +1,4 @@ -/* $Id: s_copypix.c,v 1.33 2002/02/17 17:30:23 brianp Exp $ */ +/* $Id: s_copypix.c,v 1.34 2002/03/14 22:09:25 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -379,7 +379,7 @@ copy_rgba_pixels(GLcontext *ctx, GLint srcx, GLint srcy, for (j = 0; j < height; j++, ssy += stepy) { _mesa_read_rgba_span( ctx, ctx->ReadBuffer, width, srcx, ssy, (GLchan (*)[4]) p ); - p += (width * sizeof(GLchan) * 4); + p += width * 4; } p = tmpImage; } @@ -393,7 +393,7 @@ copy_rgba_pixels(GLcontext *ctx, GLint srcx, GLint srcy, if (overlapping) { /* get from buffered image */ MEMCPY(span.color.rgba, p, width * sizeof(GLchan) * 4); - p += (width * sizeof(GLchan) * 4); + p += width * 4; } else { /* get from framebuffer */ |