From 016052c18ff6f7ea7f4cf0e7e93c796688f772ed Mon Sep 17 00:00:00 2001 From: Michal Krol Date: Fri, 3 Apr 2009 08:26:53 +0200 Subject: [PATCH] python/regress: Add vertex shader source modifier tests. --- .../regress/vertex-shader/vert-srcmod-abs.sh | 15 +++++++++++++++ .../regress/vertex-shader/vert-srcmod-absneg.sh | 16 ++++++++++++++++ .../regress/vertex-shader/vert-srcmod-neg.sh | 12 ++++++++++++ .../regress/vertex-shader/vert-srcmod-swz.sh | 12 ++++++++++++ .../tests/regress/vertex-shader/vertex-shader.py | 4 ++++ 5 files changed, 59 insertions(+) create mode 100644 src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-abs.sh create mode 100644 src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-absneg.sh create mode 100644 src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-neg.sh create mode 100644 src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-swz.sh diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-abs.sh b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-abs.sh new file mode 100644 index 00000000000..6db417a62e5 --- /dev/null +++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-abs.sh @@ -0,0 +1,15 @@ +VERT1.1 + +DCL IN[0], POSITION +DCL IN[1], COLOR +DCL OUT[0], POSITION +DCL OUT[1], COLOR +DCL TEMP[0] + +IMM FLT32 { 0.1, 0.1, 0.0, 0.0 } + +ADD TEMP[0], IN[0], IMM[0] +MOV OUT[0], |TEMP[0]| +MOV OUT[1], IN[1] + +END diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-absneg.sh b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-absneg.sh new file mode 100644 index 00000000000..fc832380520 --- /dev/null +++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-absneg.sh @@ -0,0 +1,16 @@ +VERT1.1 + +DCL IN[0], POSITION +DCL IN[1], COLOR +DCL OUT[0], POSITION +DCL OUT[1], COLOR +DCL TEMP[0] + +IMM FLT32 { -0.2, -0.2, 0.0, 0.0 } + +ADD TEMP[0], IN[0], IMM[0] +MOV OUT[0].xy, -|TEMP[0]| +MOV OUT[0].zw, IN[0] +MOV OUT[1], IN[1] + +END diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-neg.sh b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-neg.sh new file mode 100644 index 00000000000..ce4e90b5e10 --- /dev/null +++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-neg.sh @@ -0,0 +1,12 @@ +VERT1.1 + +DCL IN[0], POSITION +DCL IN[1], COLOR +DCL OUT[0], POSITION +DCL OUT[1], COLOR + +MOV OUT[0].xy, -IN[0] +MOV OUT[0].zw, IN[0] +MOV OUT[1], IN[1] + +END diff --git a/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-swz.sh b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-swz.sh new file mode 100644 index 00000000000..7617b6d5200 --- /dev/null +++ b/src/gallium/state_trackers/python/tests/regress/vertex-shader/vert-srcmod-swz.sh @@ -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] + +MOV OUT[0], IN[0].yxzw +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 4a326faa88e..7fc5f5ec514 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 @@ -223,6 +223,10 @@ def main(): 'rsq', 'sge', 'slt', + 'srcmod-abs', + 'srcmod-absneg', + 'srcmod-neg', + 'srcmod-swz', 'sub', 'xpd', ] -- 2.30.2