Mesa (master): python/regress: Add more vertex shader tests.

Michał Król michal at kemper.freedesktop.org
Wed Apr 1 01:34:20 PDT 2009


Module: Mesa
Branch: master
Commit: e8b5d170abdab9d3d750081e0371db5c3ce51c56
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=e8b5d170abdab9d3d750081e0371db5c3ce51c56

Author: Michal Krol <michal at vmware.com>
Date:   Wed Apr  1 10:18:50 2009 +0200

python/regress: Add more vertex shader tests.

---

 .../tests/regress/vertex-shader/vert-dp4.txt       |   12 ++++++++++++
 .../tests/regress/vertex-shader/vert-mul.txt       |    9 +++++++++
 .../tests/regress/vertex-shader/vert-sub.txt       |    9 +++++++++
 .../tests/regress/vertex-shader/vertex-shader.py   |    3 +++
 4 files changed, 33 insertions(+), 0 deletions(-)

diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-dp4.txt b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-dp4.txt
new file mode 100644
index 0000000..3e5f248
--- /dev/null
+++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-dp4.txt
@@ -0,0 +1,12 @@
+VERT1.1
+DCL IN[0], POSITION
+DCL IN[1], COLOR
+DCL OUT[0], POSITION
+DCL OUT[1], COLOR
+DCL TEMP[0]
+IMM FLT32 { 0.0, 0.0, 1.0, 1.0 }
+DP4 TEMP[0].xy, IN[0], IN[0]
+MOV TEMP[0].zw, IMM[0]
+MUL OUT[0], IN[0], TEMP[0]
+MOV OUT[1], IN[1]
+END
diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-mul.txt b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-mul.txt
new file mode 100644
index 0000000..1289fcd
--- /dev/null
+++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-mul.txt
@@ -0,0 +1,9 @@
+VERT1.1
+DCL IN[0], POSITION
+DCL IN[1], COLOR
+DCL OUT[0], POSITION
+DCL OUT[1], COLOR
+IMM FLT32 { 0.6, 0.6, 1.0, 1.0 }
+MUL OUT[0], IN[0], IMM[0]
+MOV OUT[1], IN[1]
+END
diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-sub.txt b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-sub.txt
new file mode 100644
index 0000000..9190086
--- /dev/null
+++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-sub.txt
@@ -0,0 +1,9 @@
+VERT1.1
+DCL IN[0], POSITION
+DCL IN[1], COLOR
+DCL OUT[0], POSITION
+DCL OUT[1], COLOR
+IMM FLT32 { 0.1, 0.1, 0.0, 0.0 }
+SUB OUT[0], IN[0], IMM[0]
+MOV OUT[1], IN[1]
+END
diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vertex-shader.py b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vertex-shader.py
index 92ff205..b393500 100644
--- a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vertex-shader.py
+++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vertex-shader.py
@@ -214,7 +214,10 @@ def main():
         'abs',
         'add',
         'dp3',
+        'dp4',
         'mov',
+        'mul',
+        'sub',
     ]
     
     html = '''<html>



More information about the mesa-commit mailing list