mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-12-04 21:31:11 -05:00
51 lines
980 B
Text
51 lines
980 B
Text
|
struct v2f {
|
||
|
vec4 vertex;
|
||
|
vec3 texcoord;
|
||
|
};
|
||
|
uniform vec4 _Tint;
|
||
|
uniform samplerCube _Tex;
|
||
|
vec4 frag (
|
||
|
in v2f i_1
|
||
|
)
|
||
|
{
|
||
|
vec4 col_2;
|
||
|
vec4 tex_3;
|
||
|
vec4 tmpvar_4;
|
||
|
tmpvar_4 = textureCube (_Tex, i_1.texcoord);
|
||
|
vec4 tmpvar_5;
|
||
|
tmpvar_5 = tmpvar_4;
|
||
|
tex_3 = tmpvar_5;
|
||
|
vec3 tmpvar_6;
|
||
|
tmpvar_6 = ((tex_3.xyz + _Tint.xyz) - 0.5);
|
||
|
col_2.xyz = tmpvar_6.xyz.xyz;
|
||
|
float tmpvar_7;
|
||
|
tmpvar_7 = (tex_3.w * _Tint.w);
|
||
|
col_2.w = vec4(tmpvar_7).w;
|
||
|
return col_2;
|
||
|
}
|
||
|
|
||
|
void main ()
|
||
|
{
|
||
|
v2f xlt_i_8;
|
||
|
vec4 xl_retval_9;
|
||
|
vec4 tmpvar_10;
|
||
|
tmpvar_10 = vec4(0.0, 0.0, 0.0, 0.0);
|
||
|
xlt_i_8.vertex = tmpvar_10;
|
||
|
vec3 tmpvar_11;
|
||
|
tmpvar_11 = gl_TexCoord[0].xyz;
|
||
|
vec3 tmpvar_12;
|
||
|
tmpvar_12 = tmpvar_11;
|
||
|
xlt_i_8.texcoord = tmpvar_12;
|
||
|
vec4 tmpvar_13;
|
||
|
tmpvar_13 = frag (xlt_i_8);
|
||
|
vec4 tmpvar_14;
|
||
|
tmpvar_14 = tmpvar_13;
|
||
|
xl_retval_9 = tmpvar_14;
|
||
|
vec4 tmpvar_15;
|
||
|
tmpvar_15 = xl_retval_9.xyzw;
|
||
|
vec4 tmpvar_16;
|
||
|
tmpvar_16 = tmpvar_15;
|
||
|
gl_FragData[0] = tmpvar_16;
|
||
|
}
|
||
|
|