[Piglit] [PATCH] util: do not call fixed functions when running core profile
Ilia Mirkin
imirkin at alum.mit.edu
Thu Nov 26 05:49:17 PST 2015
Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu>
On Thu, Nov 26, 2015 at 6:58 AM, Tapani Pälli <tapani.palli at intel.com> wrote:
> Otherwise test hits unexpected errors with piglit_draw_rect when
> running on OpenGL Core profile, using a bound program pipeline
> with vertex shader that does not use 'piglit_vertex' attribute.
>
> Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
> ---
> tests/util/piglit-util-gl.c | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/tests/util/piglit-util-gl.c b/tests/util/piglit-util-gl.c
> index 8dd4c8a..bbc174d 100644
> --- a/tests/util/piglit-util-gl.c
> +++ b/tests/util/piglit-util-gl.c
> @@ -687,10 +687,12 @@ piglit_draw_rect_from_arrays(const void *verts, const void *tex,
>
> /* If there is a current program and that program has an
> * active attribute named piglit_vertex, don't use the fixed
> - * function inputs.
> + * function inputs. Never use fixed function inputs on core
> + * profile.
> */
> - use_fixed_function_attributes = (prog == 0)
> - || glGetAttribLocation(prog, "piglit_vertex") == -1;
> + use_fixed_function_attributes = ((prog == 0)
> + || glGetAttribLocation(prog, "piglit_vertex") == -1)
> + && !piglit_is_core_profile;
> } else {
> use_fixed_function_attributes = true;
> }
> --
> 2.5.0
>
> _______________________________________________
> Piglit mailing list
> Piglit at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/piglit
More information about the Piglit
mailing list