Mesa (master): progs/fp: testcases for GL_ARB_fragment_coord_conventions
Brian Paul
brianp at kemper.freedesktop.org
Thu Jan 21 16:46:14 UTC 2010
Module: Mesa
Branch: master
Commit: 1ca22855119508457b2cbd9a0a3b840e47a61eff
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=1ca22855119508457b2cbd9a0a3b840e47a61eff
Author: Brian Paul <brianp at vmware.com>
Date: Thu Jan 21 09:38:50 2010 -0700
progs/fp: testcases for GL_ARB_fragment_coord_conventions
Based on a patch from Luca Barbieri but moved the comments after
the !!ARBfp1.0 header
---
progs/fp/position-frc-integer.txt | 7 +++++++
progs/fp/position-frc.txt | 6 ++++++
progs/fp/position-upper-left.txt | 7 +++++++
progs/fp/position.txt | 2 ++
4 files changed, 22 insertions(+), 0 deletions(-)
diff --git a/progs/fp/position-frc-integer.txt b/progs/fp/position-frc-integer.txt
new file mode 100644
index 0000000..3a634c9
--- /dev/null
+++ b/progs/fp/position-frc-integer.txt
@@ -0,0 +1,7 @@
+!!ARBfp1.0
+# expected: black triangle
+# brown means the wrong pixel center convention is being used
+OPTION ARB_fragment_coord_pixel_center_integer;
+MOV result.color, {0}.x;
+FRC result.color.xy, fragment.position;
+END
diff --git a/progs/fp/position-frc.txt b/progs/fp/position-frc.txt
new file mode 100644
index 0000000..35ae3ef
--- /dev/null
+++ b/progs/fp/position-frc.txt
@@ -0,0 +1,6 @@
+!!ARBfp1.0
+# expected: brown triangle
+# black means the wrong pixel center convention is being used
+MOV result.color, {0}.x;
+FRC result.color.xy, fragment.position;
+END
diff --git a/progs/fp/position-upper-left.txt b/progs/fp/position-upper-left.txt
new file mode 100644
index 0000000..ac632db
--- /dev/null
+++ b/progs/fp/position-upper-left.txt
@@ -0,0 +1,7 @@
+!!ARBfp1.0
+# expected: the yellow vertex is the bottom one
+# if it is the top one, the wrong origin convention is being used
+OPTION ARB_fragment_coord_origin_upper_left;
+MOV result.color, {0}.x;
+MUL result.color.xy, fragment.position, {.005}.x;
+END
diff --git a/progs/fp/position.txt b/progs/fp/position.txt
index 1875897..f59d025 100644
--- a/progs/fp/position.txt
+++ b/progs/fp/position.txt
@@ -1,4 +1,6 @@
!!ARBfp1.0
+# expected: the yellow vertex is the top one
+# if it is the bottom one, the wrong origin convention is being used
MOV result.color, {0}.x;
MUL result.color.xy, fragment.position, {.005}.x;
END
More information about the mesa-commit
mailing list