projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e2556b7
)
fix stencil value masking bug 11805, and fix sizeof() bug
author
Brian
<brian.paul@tungstengraphics.com>
Thu, 2 Aug 2007 15:08:29 +0000
(09:08 -0600)
committer
Brian
<brian.paul@tungstengraphics.com>
Thu, 2 Aug 2007 15:08:29 +0000
(09:08 -0600)
src/mesa/main/image.c
patch
|
blob
|
history
diff --git
a/src/mesa/main/image.c
b/src/mesa/main/image.c
index 8fccd44f211df889038798330745e5087c82ba50..9760e5f8d2422a09c826238a5047c6d26bc7e1c0 100644
(file)
--- a/
src/mesa/main/image.c
+++ b/
src/mesa/main/image.c
@@
-3733,7
+3733,7
@@
_mesa_pack_stencil_span( const GLcontext *ctx, GLuint n,
switch (dstType) {
case GL_UNSIGNED_BYTE:
- if (sizeof(GLstencil) ==
8
) {
+ if (sizeof(GLstencil) ==
1
) {
_mesa_memcpy( dest, source, n );
}
else {
@@
-3745,14
+3745,11
@@
_mesa_pack_stencil_span( const GLcontext *ctx, GLuint n,
}
break;
case GL_BYTE:
- if (sizeof(GLstencil) == 8) {
- _mesa_memcpy( dest, source, n );
- }
- else {
+ {
GLbyte *dst = (GLbyte *) dest;
GLuint i;
for (i=0;i<n;i++) {
- dst[i] = (GLbyte)
source[i]
;
+ dst[i] = (GLbyte)
(source[i] & 0x7f)
;
}
}
break;