varying vec2 vtc;
uniform sampler2D originalTexture, glowTexture;

varying vec4 magic;

uniform float glow;
//uniform float glownoise;

//uniform float r;
//uniform float time;

void main(void)
{
	//float noise = sin( r+magic.x*500.0)*cos(r+magic.y*502.123);

	//float noise = fract(r+sin(dot(magic.xy ,vec2(12.9898,78.233))) * 43758.5453)*2.0-0.8;

	vec4 st = texture2D(glowTexture, vtc)*glow;

	//float l = length(st.xyz);

	//noise*=glownoise*l;

	//st += vec4(noise);

	gl_FragColor  = texture2D(originalTexture, vtc)+st;
}
