123456789101112131415161718 |
- {
- "ver": "1.0.27",
- "uuid": "d9554ae7-5e70-4c17-9a55-6eae874163df",
- "importer": "effect",
- "compiledShaders": [
- {
- "glsl1": {
- "vert": "\nprecision highp float;\nuniform mat4 cc_matViewProj;\nattribute vec3 a_position;\nattribute mediump vec2 a_uv0;\nvarying mediump vec2 v_uv0;\nattribute vec4 a_color;\nvarying vec4 v_color;\nvoid main () {\n gl_Position = cc_matViewProj * vec4(a_position, 1);\n v_uv0 = a_uv0;\n v_color = a_color;\n}",
- "frag": "\nprecision highp float;\nuniform float time;\nuniform float speed;\nuniform sampler2D texture;\nvarying mediump vec2 v_uv0;\nvarying vec4 v_color;\nvoid main () {\n vec2 uv = v_uv0.xy;\n uv.y += time * speed;\n uv.y = fract(uv.y);\n vec4 color = texture2D(texture, uv);\n gl_FragColor = color;\n}"
- },
- "glsl3": {
- "vert": "\nprecision highp float;\nuniform 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};\nin vec3 a_position;\nin mediump vec2 a_uv0;\nout mediump vec2 v_uv0;\nin vec4 a_color;\nout vec4 v_color;\nvoid main () {\n gl_Position = cc_matViewProj * vec4(a_position, 1);\n v_uv0 = a_uv0;\n v_color = a_color;\n}",
- "frag": "\nprecision highp float;\nuniform Time {\n float time;\n};\nuniform SPEED {\n float speed;\n};\nuniform sampler2D texture;\nin mediump vec2 v_uv0;\nin vec4 v_color;\nvoid main () {\n vec2 uv = v_uv0.xy;\n uv.y += time * speed;\n uv.y = fract(uv.y);\n vec4 color = texture2D(texture, uv);\n gl_FragColor = color;\n}"
- }
- }
- ],
- "subMetas": {}
- }
|