Henri Verbeet
f732fb7889
Release 1.17.
2025-08-21 12:52:13 +02:00
Nikolay Sivov
2c49f04411
vkd3d-shader/fx: Do not attempt to parse expressions without code section.
2025-07-28 16:22:13 +02:00
Nikolay Sivov
dcd1747f12
vkd3d-shader/fx: Handle regular shader blobs when parsing the state data.
...
For the pass shader states this blob will contain compiled shaders, for other
state types it will contain expression code. Complex state data is stored separately,
tracing it back to actual state type will require keeping track of already parsed states.
2025-07-28 16:21:32 +02:00
Nikolay Sivov
3163e589bc
vkd3d-shader/fx: Explicitly handle bool state values when parsing.
...
For bools 0/1 values are treated as named values, outside of this
range it's zero/non-zero.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-07-14 18:38:21 +02:00
Nikolay Sivov
46c75137c7
vkd3d-shader/fx: Use the correct value range for bools in fx_4_0 state values.
...
The earlier fix a06ecb6867
is missing this.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-07-14 18:38:21 +02:00
Nikolay Sivov
fc77bddb9c
vkd3d-shader/fx: Improve register naming in the disassembly output.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-07-14 18:29:10 +02:00
Nikolay Sivov
ba5d5a8091
vkd3d-shader/fx: Fix the order of the "MaterialDiffuse" and "MaterialAmbient" state entries.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-23 18:28:41 +02:00
Nikolay Sivov
92c711a7d5
vkd3d-shader/fx: Add a format-specific callback to write state assignments.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-23 18:27:11 +02:00
Nikolay Sivov
3537feb45c
vkd3d-shader/fx: Move entry count updates out of the state block writing helper.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-23 18:17:48 +02:00
Nikolay Sivov
43a29044d6
vkd3d-shader/fx: Move state decomposition to the fx_4_0-specific writing path.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-23 18:16:17 +02:00
Nikolay Sivov
9f9cf59b6e
vkd3d-shader/fx: Use the same state data helpers for both fx_2_0 and fx_4+.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-23 18:12:27 +02:00
Nikolay Sivov
99d61aeb89
vkd3d-shader/fx: Use a version-independent structure for states.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-23 18:12:27 +02:00
Nikolay Sivov
7281f4ed39
vkd3d-shader/fx: Add support for tx -> text output.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-16 16:19:47 +02:00
Nikolay Sivov
586b2b5a79
vkd3d-shader/fx: Add the "noise" opcode name.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-16 16:07:35 +02:00
Nikolay Sivov
e28af05957
vkd3d-shader/fx: Output indirect register access in arguments.
...
This uses the notation from Wine's d3dx9 effects runtime implementation.
Indirect addressing in fx_4_0 looks pretty much broken - it compiles
to something that produces non-sensical text disassembly and fails
runtime effect creation.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-16 16:06:41 +02:00
Nikolay Sivov
3f6013ea27
vkd3d-shader/fx: Output value expressions for fx_2_0.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-16 16:04:52 +02:00
Nikolay Sivov
ddb433d552
vkd3d-shader/fx: Explicitly check all known state assignment types for fx_2_0.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-16 16:04:52 +02:00
Nikolay Sivov
590ea03255
vkd3d-shader/fx: Remove the unused fx_4_fxlc_argument type.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-16 16:04:34 +02:00
Nikolay Sivov
1913f5e6f9
vkd3d-shader/fx: Parse array selector expressions for fx_2_0.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 20:09:05 +02:00
Nikolay Sivov
90032acbcf
vkd3d-shader/fx: Rename the constant argument helper to be version-neutral.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 20:08:59 +02:00
Nikolay Sivov
d403705de9
vkd3d-shader/fx: Add a helper to print literals.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 20:07:38 +02:00
Nikolay Sivov
b098af3ef8
vkd3d-shader/fx: Use more generic names for the literal constant array.
...
It's going to be reused for 64-bit floats too.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 20:07:25 +02:00
Nikolay Sivov
f525399545
vkd3d-shader/fx: Read instruction arguments in full before printing them.
...
The binary format stores destination argument after sources. Each
argument takes either 3 tokens or 5 tokens, when indexed. For simplicity
read them all first, and print destination first.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 20:04:27 +02:00
Nikolay Sivov
d6a4084321
vkd3d-shader/fx: Use a version-neutral name for the opcode table.
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 18:25:42 +02:00
Nikolay Sivov
47b9316a86
vkd3d-shader/fx: Give fxlvm-specific constants a version-neutral name.
...
Those are reusable for fx_2_0 preshaders.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com >
2025-06-11 18:21:30 +02:00