tests/shader-runner: Introduce "if" qualifier.

When the "if" qualifier is added to a directive, the directive is
skipped if the shader->minimum_shader_model is not included in the
range.

This can be used on the "probe" directives for tests that have different
expected results on different shader models, without having to resort to
[require] blocks.
This commit is contained in:
Francisco Casas
2024-01-29 20:07:39 -03:00
committed by Alexandre Julliard
parent faec42e8a1
commit 22c47e57f5
Notes: Alexandre Julliard 2024-02-13 23:11:43 +01:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/616
6 changed files with 47 additions and 55 deletions

View File

@ -60,9 +60,6 @@ draw quad
probe all rgba (3.0, 250.0, 16.0, 4.2949673e+009) 4
[require]
shader model < 6.0
[pixel shader]
float4 main() : sv_target
{
@ -73,4 +70,5 @@ float4 main() : sv_target
[test]
draw quad
probe all rgba (-1294967296.0, 3000000000.0, 0.0, 0.0) 4
if(sm<6) probe all rgba (-1294967296.0, 3000000000.0, 0.0, 0.0) 4
if(sm>=6) probe all rgba (3000000000.0, 3000000000.0, 0.0, 0.0) 4