Mesa (7.8): mesa: add render-to-texture case for MESA_FORMAT_S8_Z24

Brian Paul brianp at kemper.freedesktop.org
Mon Mar 8 16:39:00 UTC 2010


Module: Mesa
Branch: 7.8
Commit: 26aa870a0d80f8b93239a98c558402c3c9ce6445
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=26aa870a0d80f8b93239a98c558402c3c9ce6445

Author: Brian Paul <brianp at vmware.com>
Date:   Mon Mar  8 09:38:07 2010 -0700

mesa: add render-to-texture case for MESA_FORMAT_S8_Z24

---

 src/mesa/main/texrender.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/mesa/main/texrender.c b/src/mesa/main/texrender.c
index b7b23ad..9996a99 100644
--- a/src/mesa/main/texrender.c
+++ b/src/mesa/main/texrender.c
@@ -497,6 +497,11 @@ update_wrapper(GLcontext *ctx, const struct gl_renderbuffer_attachment *att)
       trb->Base.DataType = GL_UNSIGNED_INT_24_8_EXT;
       trb->Base._BaseFormat = GL_DEPTH_STENCIL;
    }
+   else if (trb->TexImage->TexFormat == MESA_FORMAT_S8_Z24) {
+      trb->Base.Format = MESA_FORMAT_S8_Z24;
+      trb->Base.DataType = GL_UNSIGNED_INT_24_8_EXT; /* not 8_24 */
+      trb->Base._BaseFormat = GL_DEPTH_STENCIL;
+   }
    else if (trb->TexImage->TexFormat == MESA_FORMAT_Z16) {
       trb->Base.Format = MESA_FORMAT_Z16;
       trb->Base.DataType = GL_UNSIGNED_SHORT;




More information about the mesa-commit mailing list