2021-08-06 19:48:32 +00:00
|
|
|
#include <metal_stdlib>
|
|
|
|
|
|
|
|
using namespace metal;
|
|
|
|
struct tint_array_wrapper {
|
|
|
|
/* 0x0000 */ float4x4 arr[2];
|
|
|
|
};
|
2022-02-04 15:39:34 +00:00
|
|
|
struct strided_arr {
|
2021-08-06 19:48:32 +00:00
|
|
|
/* 0x0000 */ float el;
|
|
|
|
/* 0x0004 */ int8_t tint_pad[12];
|
|
|
|
};
|
|
|
|
struct tint_array_wrapper_1 {
|
2022-02-04 15:39:34 +00:00
|
|
|
/* 0x0000 */ strided_arr arr[4];
|
2021-08-06 19:48:32 +00:00
|
|
|
};
|
|
|
|
struct LeftOver {
|
|
|
|
/* 0x0000 */ float4x4 worldViewProjection;
|
|
|
|
/* 0x0040 */ float time;
|
|
|
|
/* 0x0044 */ int8_t tint_pad_1[12];
|
|
|
|
/* 0x0050 */ tint_array_wrapper test2;
|
|
|
|
/* 0x00d0 */ tint_array_wrapper_1 test;
|
|
|
|
};
|
|
|
|
struct main_out {
|
|
|
|
float4 gl_Position;
|
|
|
|
float2 vUV_1;
|
|
|
|
};
|
|
|
|
struct tint_symbol_2 {
|
|
|
|
float3 position_param [[attribute(0)]];
|
|
|
|
float3 normal_param [[attribute(1)]];
|
|
|
|
float2 uv_param [[attribute(2)]];
|
|
|
|
};
|
|
|
|
struct tint_symbol_3 {
|
|
|
|
float2 vUV_1 [[user(locn0)]];
|
|
|
|
float4 gl_Position [[position]];
|
|
|
|
};
|
|
|
|
|
2021-10-28 15:00:39 +00:00
|
|
|
void main_1(thread float3* const tint_symbol_5, const constant LeftOver* const tint_symbol_6, thread float4* const tint_symbol_7, thread float2* const tint_symbol_8, thread float2* const tint_symbol_9) {
|
2021-08-06 19:48:32 +00:00
|
|
|
float4 q = 0.0f;
|
|
|
|
float3 p = 0.0f;
|
2021-08-10 16:16:55 +00:00
|
|
|
float3 const x_13 = *(tint_symbol_5);
|
2021-10-20 16:12:33 +00:00
|
|
|
q = float4(x_13[0], x_13[1], x_13[2], 1.0f);
|
2021-08-06 19:48:32 +00:00
|
|
|
float4 const x_21 = q;
|
2021-10-20 16:12:33 +00:00
|
|
|
p = float3(x_21[0], x_21[1], x_21[2]);
|
|
|
|
float const x_27 = p[0];
|
2021-10-28 15:00:39 +00:00
|
|
|
float const x_41 = (*(tint_symbol_6)).test.arr[0].el;
|
2021-10-20 16:12:33 +00:00
|
|
|
float const x_45 = (*(tint_symbol_5))[1];
|
2021-10-28 15:00:39 +00:00
|
|
|
float const x_49 = (*(tint_symbol_6)).time;
|
2021-10-20 16:12:33 +00:00
|
|
|
p[0] = (x_27 + sin(((x_41 * x_45) + x_49)));
|
|
|
|
float const x_55 = p[1];
|
2021-10-28 15:00:39 +00:00
|
|
|
float const x_57 = (*(tint_symbol_6)).time;
|
2021-10-20 16:12:33 +00:00
|
|
|
p[1] = (x_55 + sin((x_57 + 4.0f)));
|
2021-10-28 15:00:39 +00:00
|
|
|
float4x4 const x_69 = (*(tint_symbol_6)).worldViewProjection;
|
2021-08-06 19:48:32 +00:00
|
|
|
float3 const x_70 = p;
|
2021-10-28 15:00:39 +00:00
|
|
|
*(tint_symbol_7) = (x_69 * float4(x_70[0], x_70[1], x_70[2], 1.0f));
|
|
|
|
float2 const x_83 = *(tint_symbol_8);
|
|
|
|
*(tint_symbol_9) = x_83;
|
|
|
|
float const x_87 = (*(tint_symbol_7))[1];
|
|
|
|
(*(tint_symbol_7))[1] = (x_87 * -1.0f);
|
2021-08-06 19:48:32 +00:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2021-10-28 15:00:39 +00:00
|
|
|
main_out tint_symbol_inner(float3 position_param, float2 uv_param, float3 normal_param, thread float3* const tint_symbol_10, thread float2* const tint_symbol_11, thread float3* const tint_symbol_12, const constant LeftOver* const tint_symbol_13, thread float4* const tint_symbol_14, thread float2* const tint_symbol_15) {
|
|
|
|
*(tint_symbol_10) = position_param;
|
|
|
|
*(tint_symbol_11) = uv_param;
|
|
|
|
*(tint_symbol_12) = normal_param;
|
|
|
|
main_1(tint_symbol_10, tint_symbol_13, tint_symbol_14, tint_symbol_11, tint_symbol_15);
|
|
|
|
main_out const tint_symbol_4 = {.gl_Position=*(tint_symbol_14), .vUV_1=*(tint_symbol_15)};
|
2021-08-10 16:16:55 +00:00
|
|
|
return tint_symbol_4;
|
|
|
|
}
|
|
|
|
|
2021-10-28 15:00:39 +00:00
|
|
|
vertex tint_symbol_3 tint_symbol(const constant LeftOver* tint_symbol_19 [[buffer(0)]], tint_symbol_2 tint_symbol_1 [[stage_in]]) {
|
2021-08-10 16:16:55 +00:00
|
|
|
thread float3 tint_symbol_16 = 0.0f;
|
2021-10-28 15:00:39 +00:00
|
|
|
thread float2 tint_symbol_17 = 0.0f;
|
|
|
|
thread float3 tint_symbol_18 = 0.0f;
|
|
|
|
thread float4 tint_symbol_20 = 0.0f;
|
|
|
|
thread float2 tint_symbol_21 = 0.0f;
|
|
|
|
main_out const inner_result = tint_symbol_inner(tint_symbol_1.position_param, tint_symbol_1.uv_param, tint_symbol_1.normal_param, &(tint_symbol_16), &(tint_symbol_17), &(tint_symbol_18), tint_symbol_19, &(tint_symbol_20), &(tint_symbol_21));
|
2021-08-10 16:16:55 +00:00
|
|
|
tint_symbol_3 wrapper_result = {};
|
|
|
|
wrapper_result.gl_Position = inner_result.gl_Position;
|
|
|
|
wrapper_result.vUV_1 = inner_result.vUV_1;
|
|
|
|
return wrapper_result;
|
2021-08-06 19:48:32 +00:00
|
|
|
}
|
|
|
|
|