diff options
author | marha <marha@users.sourceforge.net> | 2011-09-19 13:23:24 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2011-09-19 13:23:24 +0200 |
commit | b2c925e360e2c366526de15b44603f855f94139c (patch) | |
tree | 2a963073645913b7c6d43fa04dc0aa13bda57b80 /mesalib/src/mesa/main/format_unpack.c | |
parent | 18ae1470a8dbcfe369ddf0d7e17e0ea665251ccd (diff) | |
download | vcxsrv-b2c925e360e2c366526de15b44603f855f94139c.tar.gz vcxsrv-b2c925e360e2c366526de15b44603f855f94139c.tar.bz2 vcxsrv-b2c925e360e2c366526de15b44603f855f94139c.zip |
xtrans libX11 libXext libXdmcp libXau libXft libXinerama libXmu libfontenc
mesa git update 19 sept 2011
Diffstat (limited to 'mesalib/src/mesa/main/format_unpack.c')
-rw-r--r-- | mesalib/src/mesa/main/format_unpack.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/mesalib/src/mesa/main/format_unpack.c b/mesalib/src/mesa/main/format_unpack.c index c5146f72d..dadff0556 100644 --- a/mesalib/src/mesa/main/format_unpack.c +++ b/mesalib/src/mesa/main/format_unpack.c @@ -921,7 +921,11 @@ unpack_SIGNED_R16(const void *src, GLfloat dst[4]) static void unpack_SIGNED_GR1616(const void *src, GLfloat dst[4]) { - /* XXX TODO */ + const GLuint s = *((const GLuint *) src); + dst[RCOMP] = SHORT_TO_FLOAT_TEX( s & 0xffff ); + dst[GCOMP] = SHORT_TO_FLOAT_TEX( s >> 16 ); + dst[BCOMP] = 0.0F; + dst[ACOMP] = 1.0F; } static void @@ -947,7 +951,7 @@ unpack_SIGNED_RGBA_16(const void *src, GLfloat dst[4]) static void unpack_RGBA_16(const void *src, GLfloat dst[4]) { - const GLshort *s = (const GLshort *) src; + const GLushort *s = (const GLushort *) src; dst[RCOMP] = USHORT_TO_FLOAT( s[0] ); dst[GCOMP] = USHORT_TO_FLOAT( s[1] ); dst[BCOMP] = USHORT_TO_FLOAT( s[2] ); |