summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2014-08-16 20:59:57 +1000
committerDave Airlie <airlied@redhat.com>2015-04-08 13:34:34 +1000
commitc1b63dbf2da4b4bc097226b3b17fc181ab1904c4 (patch)
tree1a497158e4d32d1ccc5d2b1a115b3e2ad612012c
parent413a3039472c8e2df7f0606d3242a10688ba763e (diff)
arb_vertex_attrib_64bit: add simple vertex input fp64 test
This just tests a single 64-bit attrib input that is truncated and used as position. Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Signed-off-by: Dave Airlie <airlied@redhat.com>
-rw-r--r--tests/spec/arb_vertex_attrib_64bit/execution/vs-fp64-input-trunc.shader_test36
1 files changed, 36 insertions, 0 deletions
diff --git a/tests/spec/arb_vertex_attrib_64bit/execution/vs-fp64-input-trunc.shader_test b/tests/spec/arb_vertex_attrib_64bit/execution/vs-fp64-input-trunc.shader_test
new file mode 100644
index 000000000..ef7759492
--- /dev/null
+++ b/tests/spec/arb_vertex_attrib_64bit/execution/vs-fp64-input-trunc.shader_test
@@ -0,0 +1,36 @@
+# test truncating a double holds precision
+[require]
+GLSL >= 1.50
+GL_ARB_gpu_shader_fp64
+GL_ARB_vertex_attrib_64bit
+
+[vertex shader]
+#version 150
+#extension GL_ARB_gpu_shader_fp64 : require
+#extension GL_ARB_vertex_attrib_64bit : require
+in dvec4 vertex;
+void main()
+{
+ gl_Position = vec4(vertex);
+}
+
+[fragment shader]
+#version 150
+#
+void main()
+{
+ gl_FragColor = vec4(0.0, 1.0, 0.0, 1.0);
+}
+
+[vertex data]
+vertex/double/2
+-1.0 -1.0
+ 1.0 -1.0
+ 1.0 1.0
+-1.0 1.0
+
+[test]
+clear color 0.0 0.0 1.0 1.0
+clear
+draw arrays GL_TRIANGLE_FAN 0 4
+probe rgba 0 0 0.0 1.0 0.0 1.0