Zebediah Figura : tests: Specify the arguments to "probe rect" as right and bottom, instead of width and height.
Alexandre Julliard
julliard at winehq.org
Fri Apr 8 14:42:28 CDT 2022
Module: vkd3d
Branch: master
Commit: d2872fa33a9c2c24cb195e606a9c2839013fa14d
URL: https://source.winehq.org/git/vkd3d.git/?a=commit;h=d2872fa33a9c2c24cb195e606a9c2839013fa14d
Author: Zebediah Figura <zfigura at codeweavers.com>
Date: Thu Apr 7 18:58:15 2022 -0500
tests: Specify the arguments to "probe rect" as right and bottom, instead of width and height.
Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
tests/conditional.shader_test | 2 +-
tests/shader_runner.c | 14 +++++++-------
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/tests/conditional.shader_test b/tests/conditional.shader_test
index 70718f11..1a1b8fee 100644
--- a/tests/conditional.shader_test
+++ b/tests/conditional.shader_test
@@ -10,4 +10,4 @@ float4 main(float4 pos : SV_POSITION) : SV_TARGET
[test]
draw quad
probe rect rgba (0, 0, 200, 480) (0.9, 0.8, 0.7, 0.6)
-probe rect rgba (200, 0, 440, 480) (0.1, 0.2, 0.3, 0.4)
+probe rect rgba (200, 0, 640, 480) (0.1, 0.2, 0.3, 0.4)
diff --git a/tests/shader_runner.c b/tests/shader_runner.c
index 05c0fbe1..6f4c7003 100644
--- a/tests/shader_runner.c
+++ b/tests/shader_runner.c
@@ -419,22 +419,22 @@ static void parse_test_directive(struct shader_runner *runner, const char *line)
}
else if (match_string(line, "probe rect rgba", &line))
{
- unsigned int x, y, w, h, ulps;
+ unsigned int left, top, right, bottom, ulps;
struct vec4 v;
RECT rect;
int ret;
- ret = sscanf(line, "( %u , %u , %u , %u ) ( %f , %f , %f , %f ) %u",
- &x, &y, &w, &h, &v.x, &v.y, &v.z, &v.w, &ulps);
+ ret = sscanf(line, "( %d , %d , %d , %d ) ( %f , %f , %f , %f ) %u",
+ &left, &top, &right, &bottom, &v.x, &v.y, &v.z, &v.w, &ulps);
if (ret < 8)
fatal_error("Malformed probe arguments '%s'.\n", line);
if (ret < 9)
ulps = 0;
- rect.left = x;
- rect.right = x + w;
- rect.top = y;
- rect.bottom = y + h;
+ rect.left = left;
+ rect.top = top;
+ rect.right = right;
+ rect.bottom = bottom;
runner->ops->probe_vec4(runner, &rect, &v, ulps);
}
else if (match_string(line, "probe rgba", &line))
More information about the wine-cvs
mailing list