mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-04-13 05:43:18 -07:00
vkd3d-shader/spirv: Handle the TAN instruction in spirv_compiler_emit_ext_glsl_instruction().
This commit is contained in:
committed by
Alexandre Julliard
parent
93d7c30395
commit
f954724870
Notes:
Alexandre Julliard
2024-01-25 23:10:02 +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/595
@ -6982,6 +6982,7 @@ static enum GLSLstd450 spirv_compiler_map_ext_glsl_instruction(
|
|||||||
{VKD3DSIH_ROUND_Z, GLSLstd450Trunc},
|
{VKD3DSIH_ROUND_Z, GLSLstd450Trunc},
|
||||||
{VKD3DSIH_RSQ, GLSLstd450InverseSqrt},
|
{VKD3DSIH_RSQ, GLSLstd450InverseSqrt},
|
||||||
{VKD3DSIH_SQRT, GLSLstd450Sqrt},
|
{VKD3DSIH_SQRT, GLSLstd450Sqrt},
|
||||||
|
{VKD3DSIH_TAN, GLSLstd450Tan},
|
||||||
{VKD3DSIH_UMAX, GLSLstd450UMax},
|
{VKD3DSIH_UMAX, GLSLstd450UMax},
|
||||||
{VKD3DSIH_UMIN, GLSLstd450UMin},
|
{VKD3DSIH_UMIN, GLSLstd450UMin},
|
||||||
};
|
};
|
||||||
@ -9555,6 +9556,7 @@ static int spirv_compiler_handle_instruction(struct spirv_compiler *compiler,
|
|||||||
case VKD3DSIH_ROUND_Z:
|
case VKD3DSIH_ROUND_Z:
|
||||||
case VKD3DSIH_RSQ:
|
case VKD3DSIH_RSQ:
|
||||||
case VKD3DSIH_SQRT:
|
case VKD3DSIH_SQRT:
|
||||||
|
case VKD3DSIH_TAN:
|
||||||
case VKD3DSIH_UMAX:
|
case VKD3DSIH_UMAX:
|
||||||
case VKD3DSIH_UMIN:
|
case VKD3DSIH_UMIN:
|
||||||
spirv_compiler_emit_ext_glsl_instruction(compiler, instruction);
|
spirv_compiler_emit_ext_glsl_instruction(compiler, instruction);
|
||||||
|
@ -13,7 +13,7 @@ float4 main(float tex : texcoord) : sv_target
|
|||||||
}
|
}
|
||||||
|
|
||||||
[test]
|
[test]
|
||||||
todo(sm<4 | sm>=6) draw quad
|
todo(sm<4) draw quad
|
||||||
probe ( 0, 0) rgba ( 0.00000000, 1.00000000, 0.00000000, 0.0)
|
probe ( 0, 0) rgba ( 0.00000000, 1.00000000, 0.00000000, 0.0)
|
||||||
probe ( 1, 0) rgba ( 0.84147098, 0.54030231, 1.55740772, 0.0) 1024
|
probe ( 1, 0) rgba ( 0.84147098, 0.54030231, 1.55740772, 0.0) 1024
|
||||||
probe ( 2, 0) rgba ( 0.90929743, -0.41614684, -2.18503986, 0.0) 1024
|
probe ( 2, 0) rgba ( 0.90929743, -0.41614684, -2.18503986, 0.0) 1024
|
||||||
@ -72,5 +72,5 @@ float4 main() : sv_target
|
|||||||
% tan(pi/2) is an asymtote and therefore undefined
|
% tan(pi/2) is an asymtote and therefore undefined
|
||||||
% so check 0, pi/4, 3pi/4, pi
|
% so check 0, pi/4, 3pi/4, pi
|
||||||
uniform 0 float4 0.0 0.78539816 2.35619449 3.14159265
|
uniform 0 float4 0.0 0.78539816 2.35619449 3.14159265
|
||||||
todo(sm<4 | sm>=6) draw quad
|
todo(sm<4) draw quad
|
||||||
probe all rgba (0, 1000, -1000.0, 0)
|
probe all rgba (0, 1000, -1000.0, 0)
|
||||||
|
Reference in New Issue
Block a user