mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-12-11 00:31:28 -05:00
128 lines
3.2 KiB
Text
128 lines
3.2 KiB
Text
varying highp vec4 xlv_TEXCOORD0;
|
|
void main ()
|
|
{
|
|
mediump vec4 c_1;
|
|
c_1 = vec4(0.0, 0.0, 0.0, 0.0);
|
|
highp float tmpvar_2;
|
|
tmpvar_2 = (xlv_TEXCOORD0.x / 2.0);
|
|
highp float tmpvar_3;
|
|
tmpvar_3 = (fract(abs(tmpvar_2)) * 2.0);
|
|
highp float tmpvar_4;
|
|
if ((tmpvar_2 >= 0.0)) {
|
|
tmpvar_4 = tmpvar_3;
|
|
} else {
|
|
tmpvar_4 = -(tmpvar_3);
|
|
};
|
|
c_1.x = tmpvar_4;
|
|
highp vec2 tmpvar_5;
|
|
tmpvar_5 = (xlv_TEXCOORD0.xy / vec2(2.0, 2.0));
|
|
highp vec2 tmpvar_6;
|
|
tmpvar_6 = (fract(abs(tmpvar_5)) * vec2(2.0, 2.0));
|
|
highp float tmpvar_7;
|
|
if ((tmpvar_5.x >= 0.0)) {
|
|
tmpvar_7 = tmpvar_6.x;
|
|
} else {
|
|
tmpvar_7 = -(tmpvar_6.x);
|
|
};
|
|
highp float tmpvar_8;
|
|
if ((tmpvar_5.y >= 0.0)) {
|
|
tmpvar_8 = tmpvar_6.y;
|
|
} else {
|
|
tmpvar_8 = -(tmpvar_6.y);
|
|
};
|
|
highp vec2 tmpvar_9;
|
|
tmpvar_9.x = tmpvar_7;
|
|
tmpvar_9.y = tmpvar_8;
|
|
c_1.xy = (c_1.xy + tmpvar_9);
|
|
highp vec3 tmpvar_10;
|
|
tmpvar_10 = (xlv_TEXCOORD0.xyz / vec3(2.0, 2.0, 2.0));
|
|
highp vec3 tmpvar_11;
|
|
tmpvar_11 = (fract(abs(tmpvar_10)) * vec3(2.0, 2.0, 2.0));
|
|
highp float tmpvar_12;
|
|
if ((tmpvar_10.x >= 0.0)) {
|
|
tmpvar_12 = tmpvar_11.x;
|
|
} else {
|
|
tmpvar_12 = -(tmpvar_11.x);
|
|
};
|
|
highp float tmpvar_13;
|
|
if ((tmpvar_10.y >= 0.0)) {
|
|
tmpvar_13 = tmpvar_11.y;
|
|
} else {
|
|
tmpvar_13 = -(tmpvar_11.y);
|
|
};
|
|
highp float tmpvar_14;
|
|
if ((tmpvar_10.z >= 0.0)) {
|
|
tmpvar_14 = tmpvar_11.z;
|
|
} else {
|
|
tmpvar_14 = -(tmpvar_11.z);
|
|
};
|
|
highp vec3 tmpvar_15;
|
|
tmpvar_15.x = tmpvar_12;
|
|
tmpvar_15.y = tmpvar_13;
|
|
tmpvar_15.z = tmpvar_14;
|
|
c_1.xyz = (c_1.xyz + tmpvar_15);
|
|
highp vec4 tmpvar_16;
|
|
tmpvar_16 = (xlv_TEXCOORD0 / vec4(2.0, 2.0, 2.0, 2.0));
|
|
highp vec4 tmpvar_17;
|
|
tmpvar_17 = (fract(abs(tmpvar_16)) * vec4(2.0, 2.0, 2.0, 2.0));
|
|
highp float tmpvar_18;
|
|
if ((tmpvar_16.x >= 0.0)) {
|
|
tmpvar_18 = tmpvar_17.x;
|
|
} else {
|
|
tmpvar_18 = -(tmpvar_17.x);
|
|
};
|
|
highp float tmpvar_19;
|
|
if ((tmpvar_16.y >= 0.0)) {
|
|
tmpvar_19 = tmpvar_17.y;
|
|
} else {
|
|
tmpvar_19 = -(tmpvar_17.y);
|
|
};
|
|
highp float tmpvar_20;
|
|
if ((tmpvar_16.z >= 0.0)) {
|
|
tmpvar_20 = tmpvar_17.z;
|
|
} else {
|
|
tmpvar_20 = -(tmpvar_17.z);
|
|
};
|
|
highp float tmpvar_21;
|
|
if ((tmpvar_16.w >= 0.0)) {
|
|
tmpvar_21 = tmpvar_17.w;
|
|
} else {
|
|
tmpvar_21 = -(tmpvar_17.w);
|
|
};
|
|
highp vec4 tmpvar_22;
|
|
tmpvar_22.x = tmpvar_18;
|
|
tmpvar_22.y = tmpvar_19;
|
|
tmpvar_22.z = tmpvar_20;
|
|
tmpvar_22.w = tmpvar_21;
|
|
c_1 = (c_1 + tmpvar_22);
|
|
highp float tmpvar_23;
|
|
mediump float ip_24;
|
|
highp float tmpvar_25;
|
|
tmpvar_25 = float(int(xlv_TEXCOORD0.x));
|
|
ip_24 = tmpvar_25;
|
|
tmpvar_23 = (xlv_TEXCOORD0.x - ip_24);
|
|
c_1.x = (c_1.x + tmpvar_23);
|
|
highp vec2 tmpvar_26;
|
|
mediump vec2 ip_27;
|
|
highp vec2 tmpvar_28;
|
|
tmpvar_28 = vec2(ivec2(xlv_TEXCOORD0.xy));
|
|
ip_27 = tmpvar_28;
|
|
tmpvar_26 = (xlv_TEXCOORD0.xy - ip_27);
|
|
c_1.xy = (c_1.xy + tmpvar_26);
|
|
highp vec3 tmpvar_29;
|
|
mediump vec3 ip_30;
|
|
highp vec3 tmpvar_31;
|
|
tmpvar_31 = vec3(ivec3(xlv_TEXCOORD0.xyz));
|
|
ip_30 = tmpvar_31;
|
|
tmpvar_29 = (xlv_TEXCOORD0.xyz - ip_30);
|
|
c_1.xyz = (c_1.xyz + tmpvar_29);
|
|
highp vec4 tmpvar_32;
|
|
mediump vec4 ip_33;
|
|
highp vec4 tmpvar_34;
|
|
tmpvar_34 = vec4(ivec4(xlv_TEXCOORD0));
|
|
ip_33 = tmpvar_34;
|
|
tmpvar_32 = (xlv_TEXCOORD0 - ip_33);
|
|
c_1 = (c_1 + tmpvar_32);
|
|
gl_FragData[0] = c_1;
|
|
}
|
|
|