[Piglit] [PATCH] fbo-luminance-alpha: fix expected result colors
Jose Fonseca
jfonseca at vmware.com
Tue Mar 13 07:51:30 PDT 2012
Looks good to me.
Joe
----- Original Message -----
> The results of reading back a luminance/alpha texture with
> glReadPixels
> is different than the results of texturing with that texture.
>
> Fixes failures with NVIDIA driver and Mesa.
>
> http://bugs.freedesktop.org/show_bug.cgi?id=47261
> ---
> tests/fbo/fbo-luminance-alpha.c | 20 ++++++++++++--------
> 1 files changed, 12 insertions(+), 8 deletions(-)
>
> diff --git a/tests/fbo/fbo-luminance-alpha.c
> b/tests/fbo/fbo-luminance-alpha.c
> index eebad3b..b8a4766 100644
> --- a/tests/fbo/fbo-luminance-alpha.c
> +++ b/tests/fbo/fbo-luminance-alpha.c
> @@ -45,10 +45,14 @@ piglit_display(void)
> GLboolean pass = GL_TRUE;
> GLuint tex, fb;
> GLenum status;
> - float fbo_simple1[] = {0.3, 0.3, 0.3, 0.0};
> - float fbo_simple2[] = {0.6, 0.6, 0.6, 1.0};
> - float fbo_blend1[] = {0.4, 0.4, 0.4, 0.5};
> - float fbo_blend2[] = {0.56, 0.56, 0.56, 0.4};
> + float fbo_simple1[] = {0.3, 0.0, 0.0, 0.0};
> + float fbo_simple2[] = {0.6, 0.0, 0.0, 1.0};
> + float fbo_blend1[] = {0.4, 0.0, 0.0, 0.5};
> + float fbo_blend2[] = {0.56, 0.0, 0.0, 0.4};
> + float win_simple1[] = {0.3, 0.3, 0.3, 0.0};
> + float win_simple2[] = {0.6, 0.6, 0.6, 1.0};
> + float win_blend1[] = {0.4, 0.4, 0.4, 0.5};
> + float win_blend2[] = {0.56, 0.56, 0.56, 0.4};
> int fbo_width = 64;
> int fbo_height = 64;
>
> @@ -130,13 +134,13 @@ piglit_display(void)
> glDeleteFramebuffersEXT(1, &fb);
>
> printf("Testing window result, simple 1.\n");
> - pass = piglit_probe_pixel_rgba(piglit_width * 1 / 8, 0,
> fbo_simple1) && pass;
> + pass = piglit_probe_pixel_rgba(piglit_width * 1 / 8, 0,
> win_simple1) && pass;
> printf("Testing window result, simple 2.\n");
> - pass = piglit_probe_pixel_rgba(piglit_width * 3 / 8, 0,
> fbo_simple2) && pass;
> + pass = piglit_probe_pixel_rgba(piglit_width * 3 / 8, 0,
> win_simple2) && pass;
> printf("Testing window result, blending DST_ALPHA.\n");
> - pass = piglit_probe_pixel_rgba(piglit_width * 5 / 8, 0, fbo_blend1)
> && pass;
> + pass = piglit_probe_pixel_rgba(piglit_width * 5 / 8, 0, win_blend1)
> && pass;
> printf("Testing window result, blending SRC_ALPHA.\n");
> - pass = piglit_probe_pixel_rgba(piglit_width * 7 / 8, 0, fbo_blend2)
> && pass;
> + pass = piglit_probe_pixel_rgba(piglit_width * 7 / 8, 0, win_blend2)
> && pass;
>
> glutSwapBuffers();
>
> --
> 1.7.3.4
>
> _______________________________________________
> Piglit mailing list
> Piglit at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/piglit
>
--
Jose
More information about the Piglit
mailing list