• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#include <metal_stdlib>
2#include <simd/simd.h>
3using namespace metal;
4struct Inputs {
5};
6struct Outputs {
7    half4 sk_FragColor [[color(0)]];
8};
9struct Globals {
10    half2 glob;
11};
12half4 fn_h4hh2h2h3(thread Outputs& _out, thread Globals& _globals, half a, thread half2& b, thread half2& c, thread half3& d);
13half4 _skOutParamHelper0_fn_h4hh2h2h3(thread Outputs& _out, thread Globals& _globals, half _var0, thread half3& b, thread half2& glob, thread half3x3& d) {
14    half2 _var1;
15    half2 _var2 = glob.yx;
16    half3 _var3 = d[1].zyx;
17    half4 _skResult = fn_h4hh2h2h3(_out, _globals, _var0, _var1, _var2, _var3);
18    b.yz = _var1;
19    glob.yx = _var2;
20    d[1].zyx = _var3;
21    return _skResult;
22}
23half4 fn_h4hh2h2h3(thread Outputs& _out, thread Globals& _globals, half a, thread half2& b, thread half2& c, thread half3& d) {
24    a = _out.sk_FragColor.x + a;
25    b = _out.sk_FragColor.yz - _globals.glob.y;
26    c *= a;
27    d = _out.sk_FragColor.www / d;
28    return half4(a, b.x, c.y, d.x);
29}
30fragment Outputs fragmentMain(Inputs _in [[stage_in]], bool _frontFacing [[front_facing]], float4 _fragCoord [[position]]) {
31    Globals _globals{half2(1.0h)};
32    (void)_globals;
33    Outputs _out;
34    (void)_out;
35    half2 a = half2(1.0h);
36    half3 b = half3(2.0h);
37    half3x3 d = half3x3(4.0h);
38    _out.sk_FragColor =     _skOutParamHelper0_fn_h4hh2h2h3(_out, _globals, a.x, b, _globals.glob, d);
39    return _out;
40}
41