[Piglit] [PATCH v2 1/5] piglit_num_components: add more pixel unpack formats

2016-01-21 Thread Nicolai Hähnle
From: Nicolai Hähnle 

---
 tests/util/piglit-util-gl.c | 5 +
 1 file changed, 5 insertions(+)

diff --git a/tests/util/piglit-util-gl.c b/tests/util/piglit-util-gl.c
index bbc174d..61764fb 100644
--- a/tests/util/piglit-util-gl.c
+++ b/tests/util/piglit-util-gl.c
@@ -909,14 +909,19 @@ piglit_num_components(GLenum base_format)
case GL_INTENSITY:
case GL_LUMINANCE:
case GL_RED:
+   case GL_GREEN:
+   case GL_BLUE:
return 1;
case GL_DEPTH_STENCIL:
case GL_LUMINANCE_ALPHA:
case GL_RG:
return 2;
case GL_RGB:
+   case GL_BGR:
return 3;
case GL_RGBA:
+   case GL_BGRA:
+   case GL_ABGR_EXT:
return 4;
default:
printf("Unknown num_components for %s\n",
-- 
2.5.0

___
Piglit mailing list
Piglit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/piglit


Re: [Piglit] [PATCH v2 1/5] piglit_num_components: add more pixel unpack formats

2016-01-21 Thread Ilia Mirkin
On Thu, Jan 21, 2016 at 3:33 PM, Nicolai Hähnle  wrote:
> From: Nicolai Hähnle 
>
> ---
>  tests/util/piglit-util-gl.c | 5 +
>  1 file changed, 5 insertions(+)
>
> diff --git a/tests/util/piglit-util-gl.c b/tests/util/piglit-util-gl.c
> index bbc174d..61764fb 100644
> --- a/tests/util/piglit-util-gl.c
> +++ b/tests/util/piglit-util-gl.c
> @@ -909,14 +909,19 @@ piglit_num_components(GLenum base_format)

This is no longer about base formats, right? I don't think
GL_GREEN/BLUE can be base formats (or GL_BGRA). I have a mild
preference to renaming this to just "format". Not going to insist on
it though.

Either way, Reviewed-by: Ilia Mirkin 

> case GL_INTENSITY:
> case GL_LUMINANCE:
> case GL_RED:
> +   case GL_GREEN:
> +   case GL_BLUE:
> return 1;
> case GL_DEPTH_STENCIL:
> case GL_LUMINANCE_ALPHA:
> case GL_RG:
> return 2;
> case GL_RGB:
> +   case GL_BGR:
> return 3;
> case GL_RGBA:
> +   case GL_BGRA:
> +   case GL_ABGR_EXT:
> return 4;
> default:
> printf("Unknown num_components for %s\n",
> --
> 2.5.0
>
> ___
> Piglit mailing list
> Piglit@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/piglit
___
Piglit mailing list
Piglit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/piglit