projects
/
profile
/
ivi
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6e42325
)
mesa: implement unpack_SIGNED_GR1616 in format_unpack.c
author
Brian Paul
<brianp@vmware.com>
Sat, 17 Sep 2011 19:33:04 +0000
(13:33 -0600)
committer
Brian Paul
<brianp@vmware.com>
Sat, 17 Sep 2011 19:36:58 +0000
(13:36 -0600)
src/mesa/main/format_unpack.c
patch
|
blob
|
history
diff --git
a/src/mesa/main/format_unpack.c
b/src/mesa/main/format_unpack.c
index
02b5720
..
dadff05
100644
(file)
--- a/
src/mesa/main/format_unpack.c
+++ b/
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