aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main/texfetch_tmp.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2010-07-28 18:31:42 +0000
committermarha <marha@users.sourceforge.net>2010-07-28 18:31:42 +0000
commit0c0b98ae72397aeed280ffc146b16eb13065f332 (patch)
tree4a34d9ba1cc396e912aa5b473bc0a5bba968d656 /mesalib/src/mesa/main/texfetch_tmp.h
parentddf3c86d1414ac4d95e352b195ac30188f024429 (diff)
parent022d9c6cf6a67385d84ff33ce095f5c7f9f6d0cc (diff)
downloadvcxsrv-0c0b98ae72397aeed280ffc146b16eb13065f332.tar.gz
vcxsrv-0c0b98ae72397aeed280ffc146b16eb13065f332.tar.bz2
vcxsrv-0c0b98ae72397aeed280ffc146b16eb13065f332.zip
svn merge ^/branches/released .
Diffstat (limited to 'mesalib/src/mesa/main/texfetch_tmp.h')
-rw-r--r--mesalib/src/mesa/main/texfetch_tmp.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/mesalib/src/mesa/main/texfetch_tmp.h b/mesalib/src/mesa/main/texfetch_tmp.h
index e6772c89f..b11ed5c39 100644
--- a/mesalib/src/mesa/main/texfetch_tmp.h
+++ b/mesalib/src/mesa/main/texfetch_tmp.h
@@ -1215,10 +1215,10 @@ static void FETCH(signed_rgba8888)( const struct gl_texture_image *texImage,
GLint i, GLint j, GLint k, GLfloat *texel )
{
const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1);
- texel[RCOMP] = BYTE_TO_FLOAT_TEX( (s >> 24) );
- texel[GCOMP] = BYTE_TO_FLOAT_TEX( (s >> 16) & 0xff );
- texel[BCOMP] = BYTE_TO_FLOAT_TEX( (s >> 8) & 0xff );
- texel[ACOMP] = BYTE_TO_FLOAT_TEX( (s ) & 0xff );
+ texel[RCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 24) );
+ texel[GCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 16) );
+ texel[BCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 8) );
+ texel[ACOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s ) );
}
#if DIM == 3
@@ -1235,10 +1235,10 @@ static void FETCH(signed_rgba8888_rev)( const struct gl_texture_image *texImage,
GLint i, GLint j, GLint k, GLfloat *texel )
{
const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1);
- texel[RCOMP] = BYTE_TO_FLOAT_TEX( (s ) & 0xff );
- texel[GCOMP] = BYTE_TO_FLOAT_TEX( (s >> 8) & 0xff );
- texel[BCOMP] = BYTE_TO_FLOAT_TEX( (s >> 16) & 0xff );
- texel[ACOMP] = BYTE_TO_FLOAT_TEX( (s >> 24) );
+ texel[RCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s ) );
+ texel[GCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 8) );
+ texel[BCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 16) );
+ texel[ACOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 24) );
}
#if DIM == 3