[Mesa-stable] [PATCH 7/7] i965: Fix handling of MESA_pack_invert in blit (PBO) readpixels.

Anuj Phogat anuj.phogat at gmail.com
Fri Jan 3 12:53:44 PST 2014


On Mon, Dec 23, 2013 at 4:08 PM, Eric Anholt <eric at anholt.net> wrote:
> Fixes piglit GL_MESA_pack_invert/readpixels and GPU hangs with glamor and
> cairo-gl.
>
> Cc: 10.0 9.2 <mesa-stable at lists.freedesktop.org>
> ---
>  src/mesa/drivers/dri/i965/intel_pixel_read.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/src/mesa/drivers/dri/i965/intel_pixel_read.c b/src/mesa/drivers/dri/i965/intel_pixel_read.c
> index 0f6d2aa..2c85811 100644
> --- a/src/mesa/drivers/dri/i965/intel_pixel_read.c
> +++ b/src/mesa/drivers/dri/i965/intel_pixel_read.c
> @@ -106,13 +106,15 @@ do_blit_readpixels(struct gl_context * ctx,
>     /* Mesa flips the dst_stride for pack->Invert, but we want our mt to have a
>      * normal dst_stride.
>      */
> +   struct gl_pixelstore_attrib uninverted_pack = *pack;
>     if (pack->Invert) {
>        dst_stride = -dst_stride;
>        dst_flip = true;
> +      uninverted_pack.Invert = false;
>     }
>
>     dst_offset = (GLintptr)pixels;
> -   dst_offset += _mesa_image_offset(2, pack, width, height,
> +   dst_offset += _mesa_image_offset(2, &uninverted_pack, width, height,
>                                     format, type, 0, 0, 0);
>
>     if (!_mesa_clip_copytexsubimage(ctx,
> --
> 1.8.5.1
>
> _______________________________________________
> mesa-stable mailing list
> mesa-stable at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-stable

Other than one comment in [PATCH 2/7], this series is:
Reviewed-by: Anuj Phogat <anuj.phogat at gmail.com>


More information about the mesa-stable mailing list