Zebediah Figura : tests: Import HLSL static initializer tests from Wine.
Module: vkd3d Branch: master Commit: 57a8a908568bb267d3c8012016031b268169359e URL: https://source.winehq.org/git/vkd3d.git/?a=commit;h=57a8a908568bb267d3c80120... Author: Zebediah Figura <zfigura(a)codeweavers.com> Date: Sat Oct 3 16:24:25 2020 -0500 tests: Import HLSL static initializer tests from Wine. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- Makefile.am | 2 ++ tests/hlsl-static-initializer.shader_test | 15 +++++++++++++++ 2 files changed, 17 insertions(+) diff --git a/Makefile.am b/Makefile.am index ce0d193..15be137 100644 --- a/Makefile.am +++ b/Makefile.am @@ -57,6 +57,7 @@ vkd3d_shader_tests = \ tests/hlsl-majority-typedef.shader_test \ tests/hlsl-return-implicit-conversion.shader_test \ tests/hlsl-return-void.shader_test \ + tests/hlsl-static-initializer.shader_test \ tests/hlsl-struct-assignment.shader_test \ tests/hlsl-struct-varying.shader_test \ tests/hlsl-vector-indexing.shader_test \ @@ -197,6 +198,7 @@ XFAIL_TESTS = \ tests/hlsl-majority-typedef.shader_test \ tests/hlsl-return-implicit-conversion.shader_test \ tests/hlsl-return-void.shader_test \ + tests/hlsl-static-initializer.shader_test \ tests/hlsl-struct-assignment.shader_test \ tests/hlsl-struct-varying.shader_test \ tests/hlsl-vector-indexing.shader_test \ diff --git a/tests/hlsl-static-initializer.shader_test b/tests/hlsl-static-initializer.shader_test new file mode 100644 index 0000000..9b9d000 --- /dev/null +++ b/tests/hlsl-static-initializer.shader_test @@ -0,0 +1,15 @@ +[pixel shader] +float myfunc() +{ + return 0.6; +} +static float a = myfunc() + 0.2; +static float b; +float4 main() : sv_target +{ + return float4(a, b, 0, 0); +} + +[test] +draw quad +probe all rgba (0.8, 0.0, 0.0, 0.0)
participants (1)
-
Alexandre Julliard