{ "ver": "1.0.25", "uuid": "9d24dc19-8d72-483a-903d-914ccf86f169", "compiledShaders": [ { "glsl1": { "vert": "uniform mat4 cc_matViewProj;\nprecision highp float;\nattribute vec3 a_position;\nattribute vec2 a_uv0;\nvarying vec2 uv0;\nvoid main () {\n gl_Position = cc_matViewProj * vec4(a_position, 1);\n uv0 = a_uv0;\n}", "frag": "\nprecision highp float;\nvarying vec2 uv0;\nuniform sampler2D texture;\nuniform vec2 u_point;\nuniform float u_Strength;\nvoid mainImage( out vec4 fragColor, in vec2 fragCoord )\n{\n const int Samples = 64;\n vec2 uv = fragCoord.xy;\n vec2 dir = (fragCoord.xy-u_point.xy);\n vec4 color = vec4(0.0,0.0,0.0,0.0);\n for (int i = 0; i < Samples; i += 2)\n {\n color += texture2D(texture,uv+float(i)/float(Samples)*dir*u_Strength);\n color += texture2D(texture,uv+float(i+1)/float(Samples)*dir*u_Strength);\n }\n fragColor = color/float(Samples);\n}\nvoid main(void)\n{\n mainImage(gl_FragColor, uv0);\n}" }, "glsl3": { "vert": "uniform CCGlobal {\n mat4 cc_matView;\n mat4 cc_matViewInv;\n mat4 cc_matProj;\n mat4 cc_matProjInv;\n mat4 cc_matViewProj;\n mat4 cc_matViewProjInv;\n vec4 cc_cameraPos;\n vec4 cc_time;\n mediump vec4 cc_screenSize;\n mediump vec4 cc_screenScale;\n};\nprecision highp float;\nin vec3 a_position;\nin vec2 a_uv0;\nout vec2 uv0;\nvoid main () {\n gl_Position = cc_matViewProj * vec4(a_position, 1);\n uv0 = a_uv0;\n}", "frag": "\nprecision highp float;\nin vec2 uv0;\nuniform sampler2D texture;\nuniform ARGS{\n vec2 u_resolution;\n vec2 u_point;\n float u_Strength;\n};\nvoid mainImage( out vec4 fragColor, in vec2 fragCoord )\n{\n const int Samples = 64;\n vec2 uv = fragCoord.xy;\n vec2 dir = (fragCoord.xy-u_point.xy);\n vec4 color = vec4(0.0,0.0,0.0,0.0);\n for (int i = 0; i < Samples; i += 2)\n {\n color += texture2D(texture,uv+float(i)/float(Samples)*dir*u_Strength);\n color += texture2D(texture,uv+float(i+1)/float(Samples)*dir*u_Strength);\n }\n fragColor = color/float(Samples);\n}\nvoid main(void)\n{\n mainImage(gl_FragColor, uv0);\n}" } } ], "subMetas": {} }