For the series:

Reviewed-by: Marek Olšák <marek.ol...@amd.com>

Marek

On Mon, May 28, 2018 at 6:36 AM, Timothy Arceri <tarc...@itsqueeze.com>
wrote:

> ---
>  ...r-tessouter-inputs-quads-dlist.shader_test | 83 +++++++++++++++++++
>  1 file changed, 83 insertions(+)
>  create mode 100644 tests/spec/arb_tessellation_shader/execution/vs-tes-
> tessinner-tessouter-inputs-quads-dlist.shader_test
>
> diff --git a/tests/spec/arb_tessellation_shader/execution/vs-tes-
> tessinner-tessouter-inputs-quads-dlist.shader_test
> b/tests/spec/arb_tessellation_shader/execution/vs-tes-
> tessinner-tessouter-inputs-quads-dlist.shader_test
> new file mode 100644
> index 000000000..249843dcd
> --- /dev/null
> +++ b/tests/spec/arb_tessellation_shader/execution/vs-tes-
> tessinner-tessouter-inputs-quads-dlist.shader_test
> @@ -0,0 +1,83 @@
> +[require]
> +GLSL >= 1.50
> +GL_ARB_tessellation_shader
> +
> +
> +[vertex shader]
> +in vec4 vertex;
> +
> +void main()
> +{
> +       gl_Position = vertex;
> +}
> +
> +
> +[tessellation evaluation shader]
> +#extension GL_ARB_tessellation_shader: require
> +layout(quads) in;
> +
> +out vec4 color;
> +
> +void main() {
> +       gl_Position = vec4(gl_TessCoord.xy * 2 - 1, 0, 1);
> +       color = gl_TessLevelOuter[0] == 2.0 &&
> +               gl_TessLevelOuter[1] == 4.0 &&
> +               gl_TessLevelOuter[2] == 7.0 &&
> +               gl_TessLevelOuter[3] == 6.0 &&
> +               gl_TessLevelInner[0] == 5.0 &&
> +               gl_TessLevelInner[1] == 3.0 ?
> +                       vec4(0.0, 1.0, 0.0, 1.0) : vec4(1.0, 0.0, 0.0,
> 1.0);
> +}
> +
> +
> +[fragment shader]
> +in vec4 color;
> +
> +void main()
> +{
> +       gl_FragColor = color;
> +}
> +
> +[vertex data]
> +vertex/float/2
> +-1.0 -1.0
> + 1.0 -1.0
> +-1.0  1.0
> +-1.0  1.0
> + 1.0 -1.0
> + 1.0  1.0
> +
> +[test]
> +clear color 0.1 0.1 0.1 0.1
> +clear
> +
> +newlist GL_COMPILE
> +patch parameter vertices 4
> +patch parameter default level outer 2 4 7 6
> +patch parameter default level inner 5 3
> +draw arrays GL_PATCHES 0 6
> +endlist
> +
> +# make sure we haven't drawn anything yet
> +probe all rgba 0.1 0.1 0.1 0.1
> +
> +# Set wrong patch param to make sure the call list is respected
> +patch parameter default level outer 1 3 5 2
> +patch parameter default level inner 6 4
> +
> +calllist
> +probe all rgba 0.0 1.0 0.0 1.0
> +deletelist
> +
> +clear color 0.1 0.1 0.1 0.1
> +clear
> +
> +newlist GL_COMPILE_AND_EXECUTE
> +patch parameter vertices 4
> +patch parameter default level outer 2 4 7 6
> +patch parameter default level inner 5 3
> +draw arrays GL_PATCHES 0 6
> +endlist
> +
> +probe all rgba 0.0 1.0 0.0 1.0
> +deletelist
> --
> 2.17.0
>
> _______________________________________________
> Piglit mailing list
> Piglit@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/piglit
>
_______________________________________________
Piglit mailing list
Piglit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to