[Piglit] [PATCH] arb_shader_storage_buffer_object: Add linker test for indirect indexing of a buffer variable

Samuel Iglesias Gonsalvez siglesias at igalia.com
Mon Oct 19 01:57:01 PDT 2015


Signed-off-by: Samuel Iglesias Gonsalvez <siglesias at igalia.com>
---
 .../buffer-variable-indirect-indexing.shader_test  | 30 ++++++++++++++++++++++
 1 file changed, 30 insertions(+)
 create mode 100644 tests/spec/arb_shader_storage_buffer_object/linker/buffer-variable-indirect-indexing.shader_test

diff --git a/tests/spec/arb_shader_storage_buffer_object/linker/buffer-variable-indirect-indexing.shader_test b/tests/spec/arb_shader_storage_buffer_object/linker/buffer-variable-indirect-indexing.shader_test
new file mode 100644
index 0000000..1fedfc8
--- /dev/null
+++ b/tests/spec/arb_shader_storage_buffer_object/linker/buffer-variable-indirect-indexing.shader_test
@@ -0,0 +1,30 @@
+# Test checks the success of linking a shader with indirect indexing of
+# a buffer variable.
+
+[require]
+GL >= 3.3
+GLSL >= 3.30
+GL_ARB_shader_storage_buffer_object
+
+[fragment shader]
+
+#version 330
+#extension GL_ARB_shader_storage_buffer_object : enable
+
+
+buffer Fragments {
+   mat4 m;
+   int index;
+};
+
+in vec4 fragmentColor;
+out vec4 color;
+
+void main()
+{
+   m[index] = vec4(1.0, 1.0, 0.0, 1.0);
+   color = m[index];
+}
+
+[test]
+link success
-- 
2.1.4



More information about the Piglit mailing list