blob: 4e4046cfda22895dac84f64c9d74af1f8a88a783 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
#version 450
//TEST_DISABLED:COMPARE_GLSL:
// Test workaround for glslang issue #988
// (https://github.com/KhronosGroup/glslang/issues/988)
#if defined(__SLANG__)
__import glslang_bug_988_workaround;
uniform U
{
Foo foo;
};
vec4 doIt(Foo foo)
{
return foo.bar;
}
layout(location = 0)
out vec4 result;
void main()
{
vec4 r = doIt(foo);
result = r;
}
#else
struct Foo
{
vec4 bar;
};
layout(binding = 0)
uniform U
{
Foo foo;
};
vec4 doIt(Foo foo)
{
return foo.bar;
}
layout(location = 0)
out vec4 result;
void main()
{
Foo SLANG_tmp_0 = foo;
vec4 r = doIt(SLANG_tmp_0);
result = r;
}
#endif
|