diff mbox

glsl-1.50: check shader input is read only

Message ID 1419401515-653-1-git-send-email-t_arceri@yahoo.com.au
State New
Headers show

Commit Message

'Timothy Arceri' via Patchwork Forward Dec. 24, 2014, 6:11 a.m. UTC
---
 tests/spec/glsl-1.50/compiler/input-read-only.frag | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)
 create mode 100644 tests/spec/glsl-1.50/compiler/input-read-only.frag
diff mbox

Patch

diff --git a/tests/spec/glsl-1.50/compiler/input-read-only.frag b/tests/spec/glsl-1.50/compiler/input-read-only.frag
new file mode 100644
index 0000000..73d51d3
--- /dev/null
+++ b/tests/spec/glsl-1.50/compiler/input-read-only.frag
@@ -0,0 +1,17 @@ 
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// check_link: false
+// [end config]
+//
+// Check that an error is generated when trying
+// to change the value of a shader input.
+
+#version 150
+
+in vec4 invar;
+
+void main()
+{
+  invar = vec4(1.0);
+}