2016-03-15 11:29:53 +01:00
|
|
|
#version 450
|
|
|
|
|
2016-03-22 12:04:08 +01:00
|
|
|
uniform sampler2D tex;
|
2016-06-21 13:29:27 +02:00
|
|
|
|
2017-03-11 01:50:47 +01:00
|
|
|
uniform vec2 dirInv;
|
2016-03-15 11:29:53 +01:00
|
|
|
|
|
|
|
in vec2 texCoord;
|
2016-10-12 17:52:27 +02:00
|
|
|
out vec4 fragColor;
|
2016-03-15 11:29:53 +01:00
|
|
|
|
2017-03-11 01:50:47 +01:00
|
|
|
void main() {
|
2018-11-27 21:34:42 +01:00
|
|
|
fragColor.rgb = texture(tex, texCoord + dirInv * 5.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord + dirInv * 4.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord + dirInv * 3.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord + dirInv * 2.5).rgb;
|
2017-03-11 01:50:47 +01:00
|
|
|
fragColor.rgb += texture(tex, texCoord + dirInv * 1.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord - dirInv * 1.5).rgb;
|
2018-11-27 21:34:42 +01:00
|
|
|
fragColor.rgb += texture(tex, texCoord - dirInv * 2.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord - dirInv * 3.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord - dirInv * 4.5).rgb;
|
|
|
|
fragColor.rgb += texture(tex, texCoord - dirInv * 5.5).rgb;
|
2017-03-11 01:50:47 +01:00
|
|
|
fragColor.rgb /= vec3(11.0);
|
2016-03-15 11:29:53 +01:00
|
|
|
}
|