2022-02-03 14:44:18 -08:00
|
|
|
[pixel shader]
|
|
|
|
struct stu
|
|
|
|
{
|
|
|
|
int3 aaa;
|
|
|
|
float3 bbb;
|
|
|
|
int2 ccc;
|
|
|
|
float4 ddd;
|
|
|
|
int eee;
|
|
|
|
};
|
|
|
|
|
|
|
|
float4 main() : sv_target
|
|
|
|
{
|
|
|
|
struct stu val =
|
|
|
|
{
|
|
|
|
11, 12, 13,
|
|
|
|
21, 22, 23,
|
|
|
|
31, 32,
|
|
|
|
41, 42, 43, 44,
|
|
|
|
51
|
|
|
|
};
|
|
|
|
return val.ddd;
|
|
|
|
}
|
|
|
|
|
|
|
|
[test]
|
2024-03-19 04:36:23 -07:00
|
|
|
todo(glsl) draw quad
|
2022-02-03 14:44:18 -08:00
|
|
|
probe all rgba (41, 42, 43, 44)
|
|
|
|
|
|
|
|
|
|
|
|
[pixel shader]
|
|
|
|
struct stu
|
|
|
|
{
|
|
|
|
int3 aaa;
|
|
|
|
float3 bbb[2];
|
|
|
|
int2 ccc;
|
|
|
|
float4 ddd[3][2];
|
|
|
|
int eee;
|
|
|
|
};
|
|
|
|
|
|
|
|
float4 main() : sv_target
|
|
|
|
{
|
|
|
|
struct stu val =
|
|
|
|
{
|
|
|
|
11, 12, 13,
|
|
|
|
211, 212, 213, 221, 222, 223,
|
|
|
|
31, 32,
|
|
|
|
4111, 4112, 4113, 4114, 4121, 4122, 4123, 4124,
|
|
|
|
4211, 4212, 4213, 4214, 4221, 4222, 4223, 4224,
|
|
|
|
4311, 4312, 4313, 4314, 4321, 4322, 4323, 4324,
|
|
|
|
51
|
|
|
|
};
|
|
|
|
return val.ddd[2][0];
|
|
|
|
}
|
|
|
|
|
|
|
|
[test]
|
2024-03-19 04:36:23 -07:00
|
|
|
todo(glsl) draw quad
|
2022-02-03 14:44:18 -08:00
|
|
|
probe all rgba (4311, 4312, 4313, 4314)
|
|
|
|
|
|
|
|
|
|
|
|
[pixel shader]
|
|
|
|
struct stu
|
|
|
|
{
|
|
|
|
int3 aaa;
|
|
|
|
struct
|
|
|
|
{
|
|
|
|
float4 foo;
|
|
|
|
int2 bar;
|
|
|
|
} bbb[3];
|
|
|
|
};
|
|
|
|
|
|
|
|
float4 main() : sv_target
|
|
|
|
{
|
|
|
|
struct stu val =
|
|
|
|
{
|
|
|
|
1, 2, 3,
|
|
|
|
11, 12, 13, 14, 15, 16,
|
|
|
|
21, 22, 23, 24, 25, 26,
|
|
|
|
31, 32, 33, 34, 35, 36
|
|
|
|
};
|
|
|
|
return val.bbb[1].foo;
|
|
|
|
}
|
|
|
|
|
|
|
|
[test]
|
2024-03-19 04:36:23 -07:00
|
|
|
todo(glsl) draw quad
|
2022-02-03 14:44:18 -08:00
|
|
|
probe all rgba (21, 22, 23, 24)
|