Advertisement
Guest User

Untitled

a guest
Mar 16th, 2022
25
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None
  1.  
  2. vec4 ProcessTexel()
  3. {
  4. vec2 texCoord = vTexCoord.st;
  5.  
  6. const float pi = 3.14159265358979323846;
  7. vec2 offset = vec2(0.0,0.0);
  8.  
  9. offset.y = 0.5 + 0.18 * sin(pi * 2.0 * (texCoord.y + timer * 0.45 + 400.0/8192.0)) + 0.18 * sin(pi * 2.0 * (texCoord.x * 2.0 + timer * 0.35 + 400.0/8192.0));
  10. offset.x = 0.5 + 0.18 * sin(pi * 2.0 * (texCoord.y + timer * 0.4 + 400.0/8192.0)) + 0.18 * sin(pi * 2.0 * (texCoord.x * 2.0 + timer * 0.3 + 400.0/8192.0));
  11.  
  12. // offset.y = (sin((0.1*(texCoord.y + (1.0*timer))))) + (sin(texCoord.x + timer));
  13. // offset.x = (sin(texCoord.y + timer)) + (sin(texCoord.x + timer));
  14.  
  15. texCoord += offset * 0.025;
  16.  
  17. return getTexel(texCoord);
  18. }
  19.  
  20.  
Advertisement
RAW Paste Data Copied
Advertisement