2021-07-23 13:10:12 +00:00
|
|
|
#include <metal_stdlib>
|
|
|
|
|
|
|
|
using namespace metal;
|
|
|
|
struct tint_array_wrapper {
|
|
|
|
float3 arr[2];
|
|
|
|
};
|
|
|
|
struct main_out {
|
|
|
|
float4 x_GLF_color_1;
|
|
|
|
};
|
|
|
|
struct tint_symbol_1 {
|
|
|
|
float4 x_GLF_color_1 [[color(0)]];
|
|
|
|
};
|
|
|
|
|
|
|
|
float3 func_() {
|
|
|
|
float2 v = 0.0f;
|
|
|
|
int i = 0;
|
|
|
|
int k = 0;
|
|
|
|
v = float2(1.0f, 1.0f);
|
|
|
|
i = 0;
|
|
|
|
k = 0;
|
|
|
|
while (true) {
|
|
|
|
int const x_79 = k;
|
|
|
|
if ((x_79 < 2)) {
|
|
|
|
} else {
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
float const x_83 = v.y;
|
|
|
|
if (((x_83 + 1.0f) > 4.0f)) {
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
v.y = 1.0f;
|
|
|
|
int const x_89 = i;
|
2021-07-30 08:22:58 +00:00
|
|
|
i = (x_89 + 1);
|
2021-07-23 13:10:12 +00:00
|
|
|
{
|
|
|
|
int const x_91 = k;
|
2021-07-30 08:22:58 +00:00
|
|
|
k = (x_91 + 1);
|
2021-07-23 13:10:12 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
int const x_93 = i;
|
|
|
|
if ((x_93 < 10)) {
|
|
|
|
return float3(1.0f, 0.0f, 0.0f);
|
|
|
|
} else {
|
|
|
|
return float3(0.0f, 0.0f, 1.0f);
|
|
|
|
}
|
|
|
|
return float3(0.0f, 0.0f, 0.0f);
|
|
|
|
}
|
|
|
|
|
|
|
|
void main_1(thread float4* const tint_symbol_4) {
|
|
|
|
int j = 0;
|
|
|
|
tint_array_wrapper data = {};
|
|
|
|
int j_1 = 0;
|
|
|
|
j = 0;
|
|
|
|
while (true) {
|
|
|
|
int const x_46 = j;
|
|
|
|
if ((x_46 < 1)) {
|
|
|
|
} else {
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
int const x_49 = j;
|
|
|
|
float3 const x_50 = func_();
|
|
|
|
data.arr[x_49] = x_50;
|
|
|
|
{
|
|
|
|
int const x_52 = j;
|
2021-07-30 08:22:58 +00:00
|
|
|
j = (x_52 + 1);
|
2021-07-23 13:10:12 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
j_1 = 0;
|
|
|
|
while (true) {
|
|
|
|
int const x_58 = j_1;
|
|
|
|
if ((x_58 < 1)) {
|
|
|
|
} else {
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
int const x_61 = j_1;
|
|
|
|
float3 const x_64 = func_();
|
2021-07-30 08:22:58 +00:00
|
|
|
data.arr[((4 * x_61) + 1)] = x_64;
|
2021-07-23 13:10:12 +00:00
|
|
|
{
|
|
|
|
int const x_66 = j_1;
|
2021-07-30 08:22:58 +00:00
|
|
|
j_1 = (x_66 + 1);
|
2021-07-23 13:10:12 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
float3 const x_69 = data.arr[0];
|
|
|
|
*(tint_symbol_4) = float4(x_69.x, x_69.y, x_69.z, 1.0f);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
fragment tint_symbol_1 tint_symbol() {
|
|
|
|
thread float4 tint_symbol_5 = 0.0f;
|
|
|
|
main_1(&(tint_symbol_5));
|
|
|
|
main_out const tint_symbol_2 = {.x_GLF_color_1=tint_symbol_5};
|
|
|
|
tint_symbol_1 const tint_symbol_3 = {.x_GLF_color_1=tint_symbol_2.x_GLF_color_1};
|
|
|
|
return tint_symbol_3;
|
|
|
|
}
|
|
|
|
|