mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-11-25 00:58:30 -05:00
59 lines
1.2 KiB
Text
59 lines
1.2 KiB
Text
struct v2f_img {
|
|
vec4 pos;
|
|
vec2 uv;
|
|
};
|
|
uniform sampler2D _MainTex;
|
|
vec4 frag (
|
|
in v2f_img i_1
|
|
)
|
|
{
|
|
vec4 xlat_var_output_2;
|
|
vec4 sepiaConvert_3;
|
|
float Y_4;
|
|
vec4 original_5;
|
|
vec4 tmpvar_6;
|
|
tmpvar_6 = vec4(0.191, -0.054, -0.221, 0.0);
|
|
sepiaConvert_3 = tmpvar_6;
|
|
vec4 tmpvar_7;
|
|
tmpvar_7 = texture2D (_MainTex, i_1.uv);
|
|
vec4 tmpvar_8;
|
|
tmpvar_8 = tmpvar_7;
|
|
original_5 = tmpvar_8;
|
|
float tmpvar_9;
|
|
tmpvar_9 = dot (vec3(0.299, 0.587, 0.114), original_5.xyz);
|
|
float tmpvar_10;
|
|
tmpvar_10 = tmpvar_9;
|
|
Y_4 = tmpvar_10;
|
|
vec4 tmpvar_11;
|
|
tmpvar_11 = (sepiaConvert_3 + Y_4);
|
|
xlat_var_output_2 = tmpvar_11;
|
|
float tmpvar_12;
|
|
tmpvar_12 = original_5.w;
|
|
xlat_var_output_2.w = vec4(tmpvar_12).w;
|
|
return xlat_var_output_2;
|
|
}
|
|
|
|
void main ()
|
|
{
|
|
v2f_img xlt_i_13;
|
|
vec4 xl_retval_14;
|
|
vec4 tmpvar_15;
|
|
tmpvar_15 = vec4(0.0, 0.0, 0.0, 0.0);
|
|
xlt_i_13.pos = tmpvar_15;
|
|
vec2 tmpvar_16;
|
|
tmpvar_16 = gl_TexCoord[0].xy;
|
|
vec2 tmpvar_17;
|
|
tmpvar_17 = tmpvar_16;
|
|
xlt_i_13.uv = tmpvar_17;
|
|
vec4 tmpvar_18;
|
|
tmpvar_18 = frag (xlt_i_13);
|
|
vec4 tmpvar_19;
|
|
tmpvar_19 = tmpvar_18;
|
|
xl_retval_14 = tmpvar_19;
|
|
vec4 tmpvar_20;
|
|
tmpvar_20 = xl_retval_14.xyzw;
|
|
vec4 tmpvar_21;
|
|
tmpvar_21 = tmpvar_20;
|
|
gl_FragData[0] = tmpvar_21;
|
|
}
|
|
|