Re: [Piglit] [PATCH] spec/glsl-es-1.00/linker: test pass cases for invariant conditions
Quoting Lars Hamre (2016-05-06 13:23:48) > These test the cases where gl_FragCoord and gl_PointCoord are > allowed to be declared invariant. > > Signed-off-by: Lars Hamre> > --- > > NOTE: someone with access will need to commit this after the > review process > > .../linker/glsl-fcoord-invariant-pass.shader_test | 27 + > .../linker/glsl-pcoord-invariant-pass.shader_test | 28 > ++ > 2 files changed, 55 insertions(+) > create mode 100644 > tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > create mode 100644 > tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > > diff --git > a/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > b/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > new file mode 100644 > index 000..76348a6 > --- /dev/null > +++ b/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > @@ -0,0 +1,27 @@ > +# > +# OpenGL ES 1.00 specification "Invariance and linkage": > +# > +#"For the built-in special variables, gl_FragCoord can > +#only be declared invariant if and only if gl_Position is > +#declared invariant. Similarly gl_PointCoord can only be > +#declared invariant if and only if gl_PointSize is declared > +#invariant. It is an error to declare gl_FrontFacing as invariant." > +# > +[require] > +GL ES >= 2.0 > +GLSL ES >= 1.00 > + > +[vertex shader] > +invariant gl_Position; > +void main() { > + gl_Position = vec4(0.0); > +} > + > +[fragment shader] > +invariant gl_FragCoord; > +void main() { > + gl_FragColor = vec4(gl_FragCoord.x); > +} > + > +[test] > +link success > diff --git > a/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > b/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > new file mode 100644 > index 000..c0e9673 > --- /dev/null > +++ b/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > @@ -0,0 +1,28 @@ > +# > +# OpenGL ES 1.00 specification "Invariance and linkage": > +# > +#"For the built-in special variables, gl_FragCoord can > +#only be declared invariant if and only if gl_Position is > +#declared invariant. Similarly gl_PointCoord can only be > +#declared invariant if and only if gl_PointSize is declared > +#invariant. It is an error to declare gl_FrontFacing as invariant." > +# > +[require] > +GL ES >= 2.0 > +GLSL ES >= 1.00 > + > +[vertex shader] > +invariant gl_PointSize; > +void main() { > + gl_PointSize = 1.0; > + gl_Position = vec4(0.0); > +} > + > +[fragment shader] > +invariant gl_PointCoord; > +void main() { > + gl_FragColor = vec4(gl_PointCoord.x); > +} > + > +[test] > +link success > -- > 2.5.5 > > ___ > Piglit mailing list > Piglit@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/piglit Reviewed-by: Dylan Baker I'll go ahead and push this too. Thanks. signature.asc Description: signature ___ Piglit mailing list Piglit@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/piglit
Re: [Piglit] [PATCH] spec/glsl-es-1.00/linker: test pass cases for invariant conditions
Gentle ping, if nobody has any issues I would appreciate a push. In reference to this mesa patch: https://lists.freedesktop.org/archives/mesa-dev/2016-May/116073.html Regards, Lars Hamre On Fri, May 6, 2016 at 4:23 PM, Lars Hamrewrote: > These test the cases where gl_FragCoord and gl_PointCoord are > allowed to be declared invariant. > > Signed-off-by: Lars Hamre > > --- > > NOTE: someone with access will need to commit this after the > review process > > .../linker/glsl-fcoord-invariant-pass.shader_test | 27 + > .../linker/glsl-pcoord-invariant-pass.shader_test | 28 > ++ > 2 files changed, 55 insertions(+) > create mode 100644 > tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > create mode 100644 > tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > > diff --git > a/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > b/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > new file mode 100644 > index 000..76348a6 > --- /dev/null > +++ b/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test > @@ -0,0 +1,27 @@ > +# > +# OpenGL ES 1.00 specification "Invariance and linkage": > +# > +#"For the built-in special variables, gl_FragCoord can > +#only be declared invariant if and only if gl_Position is > +#declared invariant. Similarly gl_PointCoord can only be > +#declared invariant if and only if gl_PointSize is declared > +#invariant. It is an error to declare gl_FrontFacing as invariant." > +# > +[require] > +GL ES >= 2.0 > +GLSL ES >= 1.00 > + > +[vertex shader] > +invariant gl_Position; > +void main() { > + gl_Position = vec4(0.0); > +} > + > +[fragment shader] > +invariant gl_FragCoord; > +void main() { > + gl_FragColor = vec4(gl_FragCoord.x); > +} > + > +[test] > +link success > diff --git > a/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > b/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > new file mode 100644 > index 000..c0e9673 > --- /dev/null > +++ b/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test > @@ -0,0 +1,28 @@ > +# > +# OpenGL ES 1.00 specification "Invariance and linkage": > +# > +#"For the built-in special variables, gl_FragCoord can > +#only be declared invariant if and only if gl_Position is > +#declared invariant. Similarly gl_PointCoord can only be > +#declared invariant if and only if gl_PointSize is declared > +#invariant. It is an error to declare gl_FrontFacing as invariant." > +# > +[require] > +GL ES >= 2.0 > +GLSL ES >= 1.00 > + > +[vertex shader] > +invariant gl_PointSize; > +void main() { > + gl_PointSize = 1.0; > + gl_Position = vec4(0.0); > +} > + > +[fragment shader] > +invariant gl_PointCoord; > +void main() { > + gl_FragColor = vec4(gl_PointCoord.x); > +} > + > +[test] > +link success > -- > 2.5.5 > ___ Piglit mailing list Piglit@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/piglit
[Piglit] [PATCH] spec/glsl-es-1.00/linker: test pass cases for invariant conditions
These test the cases where gl_FragCoord and gl_PointCoord are allowed to be declared invariant. Signed-off-by: Lars Hamre--- NOTE: someone with access will need to commit this after the review process .../linker/glsl-fcoord-invariant-pass.shader_test | 27 + .../linker/glsl-pcoord-invariant-pass.shader_test | 28 ++ 2 files changed, 55 insertions(+) create mode 100644 tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test create mode 100644 tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test diff --git a/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test b/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test new file mode 100644 index 000..76348a6 --- /dev/null +++ b/tests/spec/glsl-es-1.00/linker/glsl-fcoord-invariant-pass.shader_test @@ -0,0 +1,27 @@ +# +# OpenGL ES 1.00 specification "Invariance and linkage": +# +#"For the built-in special variables, gl_FragCoord can +#only be declared invariant if and only if gl_Position is +#declared invariant. Similarly gl_PointCoord can only be +#declared invariant if and only if gl_PointSize is declared +#invariant. It is an error to declare gl_FrontFacing as invariant." +# +[require] +GL ES >= 2.0 +GLSL ES >= 1.00 + +[vertex shader] +invariant gl_Position; +void main() { + gl_Position = vec4(0.0); +} + +[fragment shader] +invariant gl_FragCoord; +void main() { + gl_FragColor = vec4(gl_FragCoord.x); +} + +[test] +link success diff --git a/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test b/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test new file mode 100644 index 000..c0e9673 --- /dev/null +++ b/tests/spec/glsl-es-1.00/linker/glsl-pcoord-invariant-pass.shader_test @@ -0,0 +1,28 @@ +# +# OpenGL ES 1.00 specification "Invariance and linkage": +# +#"For the built-in special variables, gl_FragCoord can +#only be declared invariant if and only if gl_Position is +#declared invariant. Similarly gl_PointCoord can only be +#declared invariant if and only if gl_PointSize is declared +#invariant. It is an error to declare gl_FrontFacing as invariant." +# +[require] +GL ES >= 2.0 +GLSL ES >= 1.00 + +[vertex shader] +invariant gl_PointSize; +void main() { + gl_PointSize = 1.0; + gl_Position = vec4(0.0); +} + +[fragment shader] +invariant gl_PointCoord; +void main() { + gl_FragColor = vec4(gl_PointCoord.x); +} + +[test] +link success -- 2.5.5 ___ Piglit mailing list Piglit@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/piglit