vkd3d-shader/glsl: Implement VKD3DSIH_IADD.

This commit is contained in:
Henri Verbeet 2024-09-30 12:15:08 +02:00
parent 4eed6b8887
commit 944929d0da
Notes: Henri Verbeet 2024-10-07 17:53:05 +02:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1145
2 changed files with 5 additions and 4 deletions

View File

@ -1056,6 +1056,7 @@ static void vkd3d_glsl_handle_instruction(struct vkd3d_glsl_generator *gen,
switch (ins->opcode) switch (ins->opcode)
{ {
case VKD3DSIH_ADD: case VKD3DSIH_ADD:
case VKD3DSIH_IADD:
shader_glsl_binop(gen, ins, "+"); shader_glsl_binop(gen, ins, "+");
break; break;
case VKD3DSIH_AND: case VKD3DSIH_AND:

View File

@ -77,16 +77,16 @@ float4 main() : SV_TARGET
[test] [test]
uniform 0 float 0 uniform 0 float 0
todo(sm<4 | glsl) draw quad todo(sm<4) draw quad
probe (0, 0) rgba (21.0, 1.0, 24.0, 0.0) probe (0, 0) rgba (21.0, 1.0, 24.0, 0.0)
uniform 0 float 1 uniform 0 float 1
todo(sm<4 | glsl) draw quad todo(sm<4) draw quad
probe (0, 0) rgba (22.0, 0.0, 23.0, 1.0) probe (0, 0) rgba (22.0, 0.0, 23.0, 1.0)
uniform 0 float 2 uniform 0 float 2
todo(sm<4 | glsl) draw quad todo(sm<4) draw quad
probe (0, 0) rgba (23.0, 1.0, 22.0, 0.0) probe (0, 0) rgba (23.0, 1.0, 22.0, 0.0)
uniform 0 float 3 uniform 0 float 3
todo(sm<4 | glsl) draw quad todo(sm<4) draw quad
probe (0, 0) rgba (24.0, 0.0, 21.0, 1.0) probe (0, 0) rgba (24.0, 0.0, 21.0, 1.0)