mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 19:58:09 +02:00
mesa: fix unpack_Z32_FLOAT_X24S8() / unpack_Z32_FLOAT() mix-up
And use the z32f_x24s8 helper struct in unpack_Z32_FLOAT_X24S8().
Cc: "10.0" "10.1" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
(cherry picked from commit 1f4ebfaa88)
This commit is contained in:
parent
6cc6c921b1
commit
15b2587334
1 changed files with 4 additions and 4 deletions
|
|
@ -711,20 +711,20 @@ unpack_Z32(const void *src, GLfloat dst[][4], GLuint n)
|
|||
}
|
||||
|
||||
static void
|
||||
unpack_Z32_FLOAT(const void *src, GLfloat dst[][4], GLuint n)
|
||||
unpack_Z32_FLOAT_X24S8(const void *src, GLfloat dst[][4], GLuint n)
|
||||
{
|
||||
const GLfloat *s = ((const GLfloat *) src);
|
||||
const struct z32f_x24s8 *s = (const struct z32f_x24s8 *) src;
|
||||
GLuint i;
|
||||
for (i = 0; i < n; i++) {
|
||||
dst[i][0] =
|
||||
dst[i][1] =
|
||||
dst[i][2] = s[i * 2];
|
||||
dst[i][2] = s[i].z;
|
||||
dst[i][3] = 1.0F;
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
unpack_Z32_FLOAT_X24S8(const void *src, GLfloat dst[][4], GLuint n)
|
||||
unpack_Z32_FLOAT(const void *src, GLfloat dst[][4], GLuint n)
|
||||
{
|
||||
const GLfloat *s = ((const GLfloat *) src);
|
||||
GLuint i;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue