-namespace {
-
-static const char blur_vs[]=
- "varying vec2 texcoord;\n"
- "void main()\n"
- "{\n"
- " gl_Position = vec4(gl_Vertex.xy*2.0-1.0, 0.0, 1.0);\n"
- " texcoord = gl_Vertex.xy;\n"
- "}";
-
-static const char blur_fs[]=
- "uniform sampler2D source;\n"
- "uniform vec2 delta;\n"
- "uniform float factors[19];\n"
- "uniform int size;\n"
- "varying vec2 texcoord;\n"
- "void main()\n"
- "{\n"
- " gl_FragColor = vec4(0.0, 0.0, 0.0, 0.0);\n"
- " for(int i=-size; i<=size; ++i)\n"
- " gl_FragColor += texture2D(source, texcoord+delta*i)*factors[i+size];\n"
- "}";
-
-static const char combine_vs[]=
- "varying vec2 texcoord;\n"
- "void main()\n"
- "{\n"
- " gl_Position = vec4(gl_Vertex.xy*2.0-1.0, 0.0, 1.0);\n"
- " texcoord = gl_Vertex.xy;\n"
- "}";
-
-static const char combine_fs[]=
- "uniform sampler2D source;\n"
- "uniform sampler2D blurred;\n"
- "uniform float strength;\n"
- "varying vec2 texcoord;\n"
- "void main()\n"
- "{\n"
- " gl_FragColor = mix(texture2D(source, texcoord), texture2D(blurred, texcoord), strength);\n"
- "}";
-
-}
-