Lutify2D.shader 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. // Lutify - Unity Asset
  2. // Copyright (c) 2015 - Thomas Hourdel
  3. // http://www.thomashourdel.com
  4. Shader "Hidden/Lutify 2D"
  5. {
  6. Properties
  7. {
  8. _MainTex ("Base (RGB)", 2D) = "white" {}
  9. }
  10. CGINCLUDE
  11. #pragma vertex vert_img
  12. #pragma fragment frag_2d
  13. #pragma fragmentoption ARB_precision_hint_fastest
  14. ENDCG
  15. SubShader
  16. {
  17. ZTest Always Cull Off ZWrite Off
  18. Fog { Mode off }
  19. // (0) - Gamma
  20. Pass
  21. {
  22. CGPROGRAM
  23. #include "./Lutify.cginc"
  24. ENDCG
  25. }
  26. // (1) - Linear
  27. Pass
  28. {
  29. CGPROGRAM
  30. #define LUTIFY_LINEAR
  31. #include "./Lutify.cginc"
  32. ENDCG
  33. }
  34. // (2) - Gamma Split H
  35. Pass
  36. {
  37. CGPROGRAM
  38. #define LUTIFY_SPLIT_H
  39. #include "./Lutify.cginc"
  40. ENDCG
  41. }
  42. // (3) - Linear Split H
  43. Pass
  44. {
  45. CGPROGRAM
  46. #define LUTIFY_SPLIT_H
  47. #define LUTIFY_LINEAR
  48. #include "./Lutify.cginc"
  49. ENDCG
  50. }
  51. // (4) - Gamma Split V
  52. Pass
  53. {
  54. CGPROGRAM
  55. #define LUTIFY_SPLIT_V
  56. #include "./Lutify.cginc"
  57. ENDCG
  58. }
  59. // (5) - Linear Split V
  60. Pass
  61. {
  62. CGPROGRAM
  63. #define LUTIFY_SPLIT_V
  64. #define LUTIFY_LINEAR
  65. #include "./Lutify.cginc"
  66. ENDCG
  67. }
  68. // (6) - Gamma - Point Filtering
  69. Pass
  70. {
  71. CGPROGRAM
  72. #define LUTIFY_FILTERING_POINT
  73. #include "./Lutify.cginc"
  74. ENDCG
  75. }
  76. // (7) - Linear - Point Filtering
  77. Pass
  78. {
  79. CGPROGRAM
  80. #define LUTIFY_LINEAR
  81. #define LUTIFY_FILTERING_POINT
  82. #include "./Lutify.cginc"
  83. ENDCG
  84. }
  85. // (8) - Gamma Split H - Point Filtering
  86. Pass
  87. {
  88. CGPROGRAM
  89. #define LUTIFY_SPLIT_H
  90. #define LUTIFY_FILTERING_POINT
  91. #include "./Lutify.cginc"
  92. ENDCG
  93. }
  94. // (9) - Linear Split H - Point Filtering
  95. Pass
  96. {
  97. CGPROGRAM
  98. #define LUTIFY_SPLIT_H
  99. #define LUTIFY_LINEAR
  100. #define LUTIFY_FILTERING_POINT
  101. #include "./Lutify.cginc"
  102. ENDCG
  103. }
  104. // (10) - Gamma Split V - Point Filtering
  105. Pass
  106. {
  107. CGPROGRAM
  108. #define LUTIFY_SPLIT_V
  109. #define LUTIFY_FILTERING_POINT
  110. #include "./Lutify.cginc"
  111. ENDCG
  112. }
  113. // (11) - Linear Split V - Point Filtering
  114. Pass
  115. {
  116. CGPROGRAM
  117. #define LUTIFY_SPLIT_V
  118. #define LUTIFY_LINEAR
  119. #define LUTIFY_FILTERING_POINT
  120. #include "./Lutify.cginc"
  121. ENDCG
  122. }
  123. }
  124. FallBack off
  125. }