#version 400

uniform sampler2D occlusionMap;
uniform float texelSize;
smooth in vec2 VS_TexCoord;

layout(location = 0) out vec4 blurredMap;

void main()
{
	float blurred = 0.0;
	for(int i = -2; i < 2; ++i)
		blurred += texture(occlusionMap, vec2(VS_TexCoord.s + i * texelSize, VS_TexCoord.t)).r;
	
	blurredMap.r = blurred * 0.25;

	//disable blur
	//blurredMap.r = texture(occlusionMap, VS_TexCoord).r;
}
