mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-11-28 18:45:54 -05:00
21 lines
498 B
Text
21 lines
498 B
Text
struct v2f {
|
|
vec4 vertex;
|
|
vec4 color;
|
|
vec2 texcoord;
|
|
};
|
|
uniform sampler2D _MainTex;
|
|
vec4 xlat_main( in v2f i );
|
|
vec4 xlat_main( in v2f i ) {
|
|
return (i.color * texture2D( _MainTex, i.texcoord));
|
|
}
|
|
varying vec4 xlv_COLOR;
|
|
varying vec2 xlv_TEXCOORD0;
|
|
void main() {
|
|
vec4 xl_retval;
|
|
v2f xlt_i;
|
|
xlt_i.vertex = vec4(0.0);
|
|
xlt_i.color = vec4( xlv_COLOR);
|
|
xlt_i.texcoord = vec2( xlv_TEXCOORD0);
|
|
xl_retval = xlat_main( xlt_i);
|
|
gl_FragData[0] = vec4( xl_retval);
|
|
}
|