#version 330

uniform sampler2D tex;
uniform vec2 screenSize;


in vec2 fragPosScreen;
layout (location = 0) out float outputColor;


void main() {
	outputColor = 0;

	for (int i = -3; i <= 3; i++)
		for (int j = -3; j <= 3; j++)
			outputColor += texture(tex, fragPosScreen + vec2(i, j) / screenSize).r;

	outputColor /= 49.0;
	outputColor *= outputColor;
}

