summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorXiang, Haihao <haihao.xiang@intel.com>2008-09-04 11:32:52 +0800
committerXiang, Haihao <haihao.xiang@intel.com>2008-09-04 11:32:52 +0800
commit218df7f9c53db90abf3a6590f77c8e9e49aeedf5 (patch)
tree8288d85350d6d095d905c6281dbe571ffc60d2a3 /src/mesa
parentdc44bb8e9208680379b31df01b4499c3a3bde5cb (diff)
mesa: merge stencil values into depth values for MESA_FORMAT_S8_Z24
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/main/texstore.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/main/texstore.c b/src/mesa/main/texstore.c
index 1efaf97fb6..e6eb1e2cd9 100644
--- a/src/mesa/main/texstore.c
+++ b/src/mesa/main/texstore.c
@@ -2503,7 +2503,7 @@ _mesa_texstore_s8_z24(TEXSTORE_PARAMS)
for (row = 0; row < srcHeight; row++) {
GLubyte stencil[MAX_WIDTH];
GLint i;
- /* the 24 depth bits will be in the high position: */
+ /* the 24 depth bits will be in the low position: */
_mesa_unpack_depth_span(ctx, srcWidth,
GL_UNSIGNED_INT, /* dst type */
dstRow, /* dst addr */
@@ -2517,7 +2517,7 @@ _mesa_texstore_s8_z24(TEXSTORE_PARAMS)
ctx->_ImageTransferState);
/* merge stencil values into depth values */
for (i = 0; i < srcWidth; i++)
- dstRow[i] = stencil[i] << 24;
+ dstRow[i] |= stencil[i] << 24;
src += srcRowStride;
dstRow += dstRowStride / sizeof(GLuint);