From 2f07e1caa02c9dcdddc673e61eb91b83b82d283b Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 8 May 2008 17:42:18 -0600 Subject: [PATCH] gallium: fix render to depth texture --- src/mesa/state_tracker/st_atom_framebuffer.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/mesa/state_tracker/st_atom_framebuffer.c b/src/mesa/state_tracker/st_atom_framebuffer.c index c9a30e44b24..d46c3ee16c5 100644 --- a/src/mesa/state_tracker/st_atom_framebuffer.c +++ b/src/mesa/state_tracker/st_atom_framebuffer.c @@ -127,6 +127,11 @@ update_framebuffer_state( struct st_context *st ) strb = st_renderbuffer(fb->Attachment[BUFFER_DEPTH].Renderbuffer); if (strb) { strb = st_renderbuffer(strb->Base.Wrapped); + if (strb->rtt) { + /* rendering to a GL texture, may have to update surface */ + update_renderbuffer_surface(st, strb); + } + assert(strb->surface); framebuffer->zsbuf = strb->surface; } -- 2.30.2