a0c13e4ee8
It is possible for a shader to declare two plain struct types which simply share the same OpName without there being an implicit value/buffer alias relationship. For to_member_name(), make sure to use the type alias master when resolving member names. The member name may be different in a type alias master if the SPIR-V is being intentionally difficult.
28 lines
327 B
Plaintext
28 lines
327 B
Plaintext
struct T
|
|
{
|
|
float c;
|
|
};
|
|
|
|
struct T_1
|
|
{
|
|
float b;
|
|
};
|
|
|
|
static const T _18 = { 40.0f };
|
|
|
|
RWByteAddressBuffer _7 : register(u0);
|
|
RWByteAddressBuffer _10 : register(u1);
|
|
|
|
void comp_main()
|
|
{
|
|
T v = _18;
|
|
_7.Store(40, asuint(v.c));
|
|
_10.Store(480, asuint(v.c));
|
|
}
|
|
|
|
[numthreads(1, 1, 1)]
|
|
void main()
|
|
{
|
|
comp_main();
|
|
}
|