Re: [Mesa-dev] [PATCH] mesa: don't map depth+stencil buffer twice in glReadPixels()

2011-11-16 Thread Brian Paul
On 11/16/2011 09:54 AM, Vadim Girlin wrote: On Wed, 2011-11-16 at 20:41 +0400, Vadim Girlin wrote: On Wed, 2011-11-16 at 07:53 -0700, Brian Paul wrote: In slow_read_depth_stencil_pixels_separate() we might have separate depth and stencil buffers or a combined buffer. In the later case, don't m

Re: [Mesa-dev] [PATCH] mesa: don't map depth+stencil buffer twice in glReadPixels()

2011-11-16 Thread Vadim Girlin
On Wed, 2011-11-16 at 20:41 +0400, Vadim Girlin wrote: > On Wed, 2011-11-16 at 07:53 -0700, Brian Paul wrote: > > In slow_read_depth_stencil_pixels_separate() we might have separate > > depth and stencil buffers or a combined buffer. In the later case, > > don't map the buffer twice. This functio

Re: [Mesa-dev] [PATCH] mesa: don't map depth+stencil buffer twice in glReadPixels()

2011-11-16 Thread Vadim Girlin
On Wed, 2011-11-16 at 07:53 -0700, Brian Paul wrote: > In slow_read_depth_stencil_pixels_separate() we might have separate > depth and stencil buffers or a combined buffer. In the later case, > don't map the buffer twice. This function is used when the depth > scale/bias pixel transfer values are

Re: [Mesa-dev] [PATCH] mesa: don't map depth+stencil buffer twice in glReadPixels()

2011-11-16 Thread Brian Paul
On 11/16/2011 08:43 AM, Jose Fonseca wrote: Looks good Brian. BTW, we should probably be more defensive about map failures on this code. This is not a regression, as st_cb_readpixels.c also did a poor job. Yeah, it's only a matter of time until we find a case where MapRenderbuffer (or MapTex

Re: [Mesa-dev] [PATCH] mesa: don't map depth+stencil buffer twice in glReadPixels()

2011-11-16 Thread Jose Fonseca
Looks good Brian. BTW, we should probably be more defensive about map failures on this code. This is not a regression, as st_cb_readpixels.c also did a poor job. Jose - Original Message - > In slow_read_depth_stencil_pixels_separate() we might have separate > depth and stencil buffers o

[Mesa-dev] [PATCH] mesa: don't map depth+stencil buffer twice in glReadPixels()

2011-11-16 Thread Brian Paul
In slow_read_depth_stencil_pixels_separate() we might have separate depth and stencil buffers or a combined buffer. In the later case, don't map the buffer twice. This function is used when the depth scale/bias pixel transfer values are not the defaults. Fixes http://bugs.freedesktop.org/show_bu