Mesa (master): intel: Perform gather on s8z24 texture images during glGetTexImage

Chad Versace chadversary at kemper.freedesktop.org
Fri Jun 24 21:48:49 UTC 2011


Module: Mesa
Branch: master
Commit: 951b75808eeac5fb97183ea8e653512bfa35fdb2
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=951b75808eeac5fb97183ea8e653512bfa35fdb2

Author: Chad Versace <chad at chad-versace.us>
Date:   Tue Jun 21 21:42:48 2011 -0700

intel: Perform gather on s8z24 texture images during glGetTexImage

Signed-off-by: Chad Versace <chad at chad-versace.us>

---

 src/mesa/drivers/dri/intel/intel_tex_image.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/src/mesa/drivers/dri/intel/intel_tex_image.c b/src/mesa/drivers/dri/intel/intel_tex_image.c
index 6065238..4a29bc5 100644
--- a/src/mesa/drivers/dri/intel/intel_tex_image.c
+++ b/src/mesa/drivers/dri/intel/intel_tex_image.c
@@ -659,6 +659,14 @@ intel_get_tex_image(struct gl_context * ctx, GLenum target, GLint level,
       assert(intelImage->base.Data);
    }
 
+   if (intelImage->stencil_rb) {
+      /*
+       * The texture has packed depth/stencil format, but uses separate
+       * stencil. The texture's embedded stencil buffer contains the real
+       * stencil data, so copy that into the miptree.
+       */
+      intel_tex_image_s8z24_gather(intel, intelImage);
+   }
 
    if (compressed) {
       _mesa_get_compressed_teximage(ctx, target, level, pixels,




More information about the mesa-commit mailing list