mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-12-01 11:56:58 -05:00
27 lines
564 B
Text
27 lines
564 B
Text
|
struct v2f {
|
||
|
vec4 pos;
|
||
|
vec2 uv0;
|
||
|
vec2 uv1;
|
||
|
};
|
||
|
|
||
|
uniform vec4 _Color;
|
||
|
uniform sampler2D _Detail;
|
||
|
uniform sampler2D _MainTex;
|
||
|
vec4 frag( in v2f i );
|
||
|
vec4 frag( in v2f i ) {
|
||
|
vec4 c;
|
||
|
c = (_Color * texture2D( _MainTex, i.uv0));
|
||
|
c = ((c * texture2D( _Detail, i.uv1)) * 2.00000);
|
||
|
return c;
|
||
|
}
|
||
|
varying vec4 xlv_TEXCOORD0;
|
||
|
varying vec4 xlv_TEXCOORD1;
|
||
|
void main() {
|
||
|
vec4 xl_retval;
|
||
|
v2f xlt_i;
|
||
|
xlt_i.uv0 = vec2( xlv_TEXCOORD0);
|
||
|
xlt_i.uv1 = vec2( xlv_TEXCOORD1);
|
||
|
xl_retval = frag( xlt_i);
|
||
|
gl_FragData[0] = vec4( xl_retval);
|
||
|
}
|