remap.similar_1b.everything.frag 473 B

12345678910111213141516171819202122232425262728293031
  1. #version 450
  2. out vec4 outf4;
  3. in flat ivec4 ini4;
  4. in float inf;
  5. float Test1(int bound)
  6. {
  7. float r = 0;
  8. for (int x=0; x<bound; ++x)
  9. r += 0.5;
  10. r += 0.2;
  11. return r;
  12. }
  13. float Test2(int bound)
  14. {
  15. if (bound > 2) {
  16. return Test1(bound * 2);
  17. } else
  18. return float(bound * 4 +
  19. ini4.y * ini4.z +
  20. ini4.x);
  21. }
  22. void main()
  23. {
  24. outf4 = vec4(Test1(int(inf)) +
  25. Test2(int(inf)));
  26. }