aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/app_settings/shaders/class3/effects/blurF.glsl
diff options
context:
space:
mode:
Diffstat (limited to 'linden/indra/newview/app_settings/shaders/class3/effects/blurF.glsl')
-rw-r--r--linden/indra/newview/app_settings/shaders/class3/effects/blurF.glsl31
1 files changed, 31 insertions, 0 deletions
diff --git a/linden/indra/newview/app_settings/shaders/class3/effects/blurF.glsl b/linden/indra/newview/app_settings/shaders/class3/effects/blurF.glsl
new file mode 100644
index 0000000..9443320
--- /dev/null
+++ b/linden/indra/newview/app_settings/shaders/class3/effects/blurF.glsl
@@ -0,0 +1,31 @@
1/**
2 * @file blurf.glsl
3 *
4 * Copyright (c) 2007-$CurrentYear$, Linden Research, Inc.
5 * $License$
6 */
7
8uniform sampler2DRect RenderTexture;
9uniform float bloomStrength;
10
11varying vec4 gl_TexCoord[gl_MaxTextureCoords];
12void main(void)
13{
14 float blurWeights[7];
15 blurWeights[0] = 0.05;
16 blurWeights[1] = 0.1;
17 blurWeights[2] = 0.2;
18 blurWeights[3] = 0.3;
19 blurWeights[4] = 0.2;
20 blurWeights[5] = 0.1;
21 blurWeights[6] = 0.05;
22
23 vec3 color = vec3(0,0,0);
24 for (int i = 0; i < 7; i++){
25 color += vec3(texture2DRect(RenderTexture, gl_TexCoord[i].st)) * blurWeights[i];
26 }
27
28 color *= bloomStrength;
29
30 gl_FragColor = vec4(color, 1.0);
31}