vkd3d/tests/hlsl-function-overload.shader_test
Zebediah Figura 4d17758657 tests: Always compile HLSL shaders.
Do not rely on a draw or dispatch command to do this.

This allows more efficiently testing syntax, in cases where testing the actual
shader functionality is not interesting.
2022-11-08 20:52:57 +01:00

41 lines
533 B
Plaintext

[pixel shader fail]
/* The same function signature cannot be defined twice. */
float func(int arg)
{
return 0.1;
}
float func(int arg)
{
return 0.1;
}
float4 main() : sv_target
{
return 0;
}
[pixel shader todo]
/* Test a basic overload. */
float func(int arg)
{
return 0.1;
}
float func(uint arg)
{
return 0.2;
}
float4 main() : sv_target
{
int i = 1;
uint u = 1;
return float4(func(i), func(u), func(int2(1, 1)), func(uint2(1, 1)));
}
[test]
todo draw quad
probe all rgba (0.1, 0.2, 0.1, 0.2)