mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
tests/hlsl: Test uint64 comparisons.
This commit is contained in:
committed by
Henri Verbeet
parent
395d456386
commit
cc42581a34
Notes:
Henri Verbeet
2025-07-14 18:53:08 +02:00
Approved-by: Henri Verbeet (@hverbeet) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1608
@@ -259,3 +259,65 @@ uniform 0 uint 0x000bfffe
|
|||||||
uniform 1 uint 0xffffffff
|
uniform 1 uint 0xffffffff
|
||||||
draw quad
|
draw quad
|
||||||
probe (0, 0) u32(0, 2, 1, 0x3333)
|
probe (0, 0) u32(0, 2, 1, 0x3333)
|
||||||
|
|
||||||
|
[require]
|
||||||
|
shader model >= 6.0
|
||||||
|
int64
|
||||||
|
|
||||||
|
[rtv 0]
|
||||||
|
format r32g32b32a32-float
|
||||||
|
size (2d, 640, 480)
|
||||||
|
|
||||||
|
[pixel shader]
|
||||||
|
uniform uint64_t2 a;
|
||||||
|
|
||||||
|
float4 main() : SV_TARGET
|
||||||
|
{
|
||||||
|
uint64_t x = a.x;
|
||||||
|
uint64_t y = a.y;
|
||||||
|
return float4(x == y, y == x, x != y, y != x);
|
||||||
|
}
|
||||||
|
|
||||||
|
[test]
|
||||||
|
uniform 0 uint64_t2 42000000000 5000000000
|
||||||
|
draw quad
|
||||||
|
probe (0, 0) f32(0.0, 0.0, 1.0, 1.0)
|
||||||
|
uniform 0 uint64_t2 42000000000 42000000000
|
||||||
|
draw quad
|
||||||
|
probe (0, 0) f32(1.0, 1.0, 0.0, 0.0)
|
||||||
|
|
||||||
|
[pixel shader]
|
||||||
|
uniform uint64_t2 a;
|
||||||
|
|
||||||
|
float4 main() : SV_TARGET
|
||||||
|
{
|
||||||
|
uint64_t x = a.x;
|
||||||
|
uint64_t y = a.y;
|
||||||
|
return float4(x <= y, y <= x, x >= y, y >= x);
|
||||||
|
}
|
||||||
|
|
||||||
|
[test]
|
||||||
|
uniform 0 uint64_t2 42000000000 5000000000
|
||||||
|
draw quad
|
||||||
|
probe (0, 0) f32(0.0, 1.0, 1.0, 0.0)
|
||||||
|
uniform 0 uint64_t2 42000000000 42000000000
|
||||||
|
draw quad
|
||||||
|
probe (0, 0) f32(1.0, 1.0, 1.0, 1.0)
|
||||||
|
|
||||||
|
[pixel shader]
|
||||||
|
uniform uint64_t2 a;
|
||||||
|
|
||||||
|
float4 main() : SV_TARGET
|
||||||
|
{
|
||||||
|
uint64_t x = a.x;
|
||||||
|
uint64_t y = a.y;
|
||||||
|
return float4(x < y, y < x, x > y, y > x);
|
||||||
|
}
|
||||||
|
|
||||||
|
[test]
|
||||||
|
uniform 0 uint64_t2 42000000000 5000000000
|
||||||
|
draw quad
|
||||||
|
probe (0, 0) f32(0.0, 1.0, 1.0, 0.0)
|
||||||
|
uniform 0 uint64_t2 42000000000 42000000000
|
||||||
|
draw quad
|
||||||
|
probe (0, 0) f32(0.0, 0.0, 0.0, 0.0)
|
||||||
|
Reference in New Issue
Block a user