Shaun Ren
245430002a
vkd3d-shader/hlsl: Fold some general unary identities.
...
The following unary identities are applied:
||x|| -> |x|
|-x| -> |x|
~(~x) -> x
f(g(x)) -> g(x), where f(), g() are floor() or ceil() functions.
-(-x) -> x
!!x -> x
!(x == y) -> x != y, !(x < y) -> x >= y, etc (for integers).
2025-08-21 16:00:46 +02:00
Giovanni Mascellani
3817df1164
tests/shader_runner_metal: Run the Metal shader runner with DXIL shaders.
2025-08-04 14:34:23 +02:00
Henri Verbeet
9c987e5a0b
tests/shader_runner: Introduce the "u32" probe format.
2025-06-10 17:48:19 +02:00
Henri Verbeet
3673b65485
vkd3d-shader/msl: Implement VKD3DSIH_IADD.
2025-06-09 16:20:53 +02:00
Giovanni Mascellani
de8dbdc2cb
tests/hlsl: Add a test reading from a minimum precision floating-point array.
2025-06-02 20:18:30 +02:00
Giovanni Mascellani
12da0f9d24
tests/hlsl: Add some more minimum precision floating-point tests.
2025-06-02 20:18:21 +02:00
Giovanni Mascellani
dbd1938ce4
tests/hlsl: Fix the precision for a 16-bit arithmetic test.
2025-04-16 16:42:20 +02:00
Conor McCarthy
49a683f260
tests/hlsl: Add arithmetic float16 tests.
2025-02-10 13:19:16 +01:00
Giovanni Mascellani
343022cdc1
vkd3d-shader/spirv: Interpret the write mask as a destination swizzle for double comparison operations.
...
This fixes a failure on a shader in Wild hearts.
2025-01-22 14:51:16 +01:00
Elizabeth Figura
fb75c0530a
tests: Adjust arithmetic-float-uniform.shader_test to pass with 1.x.
...
Pixel shader 1.x constants must be between -1 and 1, or they will be clamped,
even constants defined in the shader.
Also mark 1.x-specific features if any.
2025-01-22 13:43:38 +01:00
Feifan He
a425c242a4
vkd3d-shader/msl: Implement VKD3DSIH_MAD.
2024-12-05 21:26:03 +01:00
Feifan He
71ce43313f
vkd3d-shader/msl: Implement VKD3DSIH_MOVC.
2024-11-25 20:43:13 +01:00
Feifan He
38d7f8415d
vkd3d-shader/msl: Implement support for VKD3DSPSM_NEG modifiers.
2024-11-25 20:43:13 +01:00
Feifan He
64ea19b7f7
vkd3d-shader/msl: Implement VKD3DSIH_DIV.
2024-11-25 20:43:13 +01:00
Feifan He
b0646cb427
tests/shader_runner: Introduce a Metal shader runner.
2024-10-31 16:47:26 +01:00
Henri Verbeet
f501b8c661
vkd3d-shader/glsl: Implement VKD3DSIH_MAD.
2024-10-02 22:30:58 +02:00
Atharva Nimbalkar
ee8e005209
vkd3d-shader/glsl: Implement VKD3DSIH_MOVC.
2024-09-23 15:41:07 +02:00
Henri Verbeet
28ef331704
vkd3d-shader/glsl: Implement support for VKD3DSPSM_NEG modifiers.
2024-09-23 15:41:07 +02:00
Henri Verbeet
b9366def96
vkd3d-shader/glsl: Implement VKD3DSIH_DIV.
2024-09-23 15:41:07 +02:00
Atharva Nimbalkar
ab07637ee1
vkd3d-shader/glsl: Implement VKD3DSIH_ADD.
2024-09-19 14:29:46 +02:00
Nikolay Sivov
de6abd964e
vkd3d-shader/hlsl: Implement the mad() intrinsic.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2024-09-10 21:40:32 +02:00
Elizabeth Figura
d3ba810c98
tests: Stop probing all pixels when drawing a uniform colour.
...
This is simply unnecessary and wastes time.
As part of this, simply remove the "all" directive. Only for a couple of tests
is it even potentially interesting to validate all pixels (e.g.
nointerpolation.shader_test), and for those "all" is replaced with an explicit
(0, 0, 640, 480) rect.
In all other cases we just probe (0, 0).
2024-06-13 23:55:31 +02:00
Francisco Casas
c43c900a30
tests: Test x + 0 and x * 1 indentities.
2024-04-30 16:31:01 +02:00
Conor McCarthy
23db066922
vkd3d-shader/ir: Implement MAD in two operations if flagged as precise.
...
With some changes by Giovanni Mascellani.
2024-04-15 21:33:35 +02:00
Francisco Casas
19fd43214b
vkd3d-shader/hlsl: Ensure that TERNARY condition is always bool.
...
Also, properly casting it to float in lower_ternary() for SM1
avoids creating ABS and NEG on bool types.
2024-04-09 12:26:59 -05:00