Nevcairiel

Untitled

Nov 24th, 2021
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.59 KB | None | 0 0
  1. PL(5): fragment shader GLSL source:
  2. PL(5): [ 1] #version 450
  3. PL(5): [ 2] #extension GL_ARB_uniform_buffer_object : enable
  4. PL(5): [ 3] #extension GL_ARB_texture_gather : enable
  5. PL(5): [ 4] layout(binding=0) uniform sampler2D _src_tex_0_1;
  6. PL(5): [ 5] layout(binding=1) uniform sampler2D _src_tex_0_2;
  7. PL(5): [ 6] layout(std140, binding=2) uniform _UBO_5_0 {
  8. PL(5): [ 7] layout(offset=0) mat3 _cmat_2_0;
  9. PL(5): [ 8] layout(offset=48) vec3 _cmat_c_3_0;
  10. PL(5): [ 9] };
  11. PL(5): [ 10] layout(location=0) in vec2 _tex_coord_1_1;
  12. PL(5): [ 11] layout(location=1) in vec2 _tex_coord_1_2;
  13. PL(5): [ 12] layout(location=0) out vec4 out_color;
  14. PL(5): [ 13]
  15. PL(5): [ 14] const float _const_2_1 = 1.00000000000000000000;
  16. PL(5): [ 15] vec4 _sub_0_0() {
  17. PL(5): [ 16] // pl_shader_sample_direct
  18. PL(5): [ 17] vec4 color = vec4(_const_2_1) * texture(_src_tex_0_1, _tex_coord_1_1);
  19. PL(5): [ 18] return color;
  20. PL(5): [ 19] }
  21. PL(5): [ 20]
  22. PL(5): [ 21] const float _const_2_2 = 1.00000000000000000000;
  23. PL(5): [ 22] vec4 _sub_1_0() {
  24. PL(5): [ 23] // pl_shader_sample_direct
  25. PL(5): [ 24] vec4 color = vec4(_const_2_2) * texture(_src_tex_0_2, _tex_coord_1_2);
  26. PL(5): [ 25] return color;
  27. PL(5): [ 26] }
  28. PL(5): [ 27]
  29. PL(5): [ 28] vec4 _main_6_0() {
  30. PL(5): [ 29] vec4 color = vec4(0.0, 0.5, 0.5, 1.0);
  31. PL(5): [ 30] // pass_read_image
  32. PL(5): [ 31] {
  33. PL(5): [ 32] vec4 tmp;
  34. PL(5): [ 33] tmp = _sub_0_0();
  35. PL(5): [ 34] color[0] = tmp[0];
  36. PL(5): [ 35] tmp = _sub_1_0();
  37. PL(5): [ 36] color[1] = tmp[0];
  38. PL(5): [ 37] color[2] = tmp[1];
  39. PL(5): [ 38] }
  40. PL(5): [ 39] // pl_shader_decode_color
  41. PL(5): [ 40] {
  42. PL(5): [ 41] color.rgb = _cmat_2_0 * color.rgb + _cmat_c_3_0;
  43. PL(5): [ 42] }
  44. PL(5): [ 43] // pl_shader_linearize
  45. PL(5): [ 44] color.rgb = max(color.rgb, 0.0);
  46. PL(5): [ 45] color.rgb = pow(color.rgb, vec3(1.0/78.84375000000000000000));
  47. PL(5): [ 46] color.rgb = max(color.rgb - vec3(0.83593750000000000000), 0.0)
  48. PL(5): [ 47] / (vec3(18.85156250000000000000) - vec3(18.68750000000000000000) * color.rgb);
  49. PL(5): [ 48] color.rgb = pow(color.rgb, vec3(1.0/0.15930175781250000000));
  50. PL(5): [ 49] color.rgb *= vec3(49.26108374384236298501);
  51. PL(5): [ 50] return color;
  52. PL(5): [ 51] }
  53. PL(5): [ 52]
  54. PL(5): [ 53] void main() {
  55. PL(5): [ 54] out_color = _main_6_0();
  56. PL(5): [ 55] }
  57. PL(5): fragment shader GLSL source:
  58. PL(5): [ 1] #version 450
  59. PL(5): [ 2] #extension GL_ARB_uniform_buffer_object : enable
  60. PL(5): [ 3] #extension GL_ARB_texture_gather : enable
  61. PL(5): [ 4] layout(binding=0) uniform sampler2D _src_tex_0_3;
  62. PL(5): [ 5] layout(binding=1) uniform sampler2D _weights_5_3;
  63. PL(5): [ 6] layout(binding=2) uniform sampler2D _weights_14_3;
  64. PL(5): [ 7] layout(std140, binding=3) uniform _UBO_20_3 {
  65. PL(5): [ 8] layout(offset=0) vec2 _tex_size_2_3;
  66. PL(5): [ 9] layout(offset=8) vec2 _tex_pt_3_3;
  67. PL(5): [ 10] };
  68. PL(5): [ 11] layout(location=0) in vec2 _tex_coord_1_3;
  69. PL(5): [ 12] layout(location=0) out vec4 out_color;
  70. PL(5): [ 13]
  71. PL(5): [ 14] const float _const_7_3 = 0.75000000000000000000;
  72. PL(5): [ 15] const float _const_8_3 = 0.25000000000000000000;
  73. PL(5): [ 16] #define _LUT_POS_6_3(x) mix(_const_8_3, _const_7_3, (x))
  74. PL(5): [ 17] const float _const_10_3 = 0.99218750000000000000;
  75. PL(5): [ 18] const float _const_11_3 = 0.00781250000000000000;
  76. PL(5): [ 19] #define _LUT_POS_9_3(x) mix(_const_11_3, _const_10_3, (x))
  77. PL(5): [ 20] #define _lut_4_3(pos) (texture(_weights_5_3, vec2(\
  78. PL(5): [ 21] _LUT_POS_6_3(vec2(pos).x)\
  79. PL(5): [ 22] ,_LUT_POS_9_3(vec2(pos).y)\
  80. PL(5): [ 23] )).xyzw)
  81. PL(5): [ 24] const float _const_12_3 = 1.00000000000000000000;
  82. PL(5): [ 25] #define _lut_13_3(pos) (texelFetch(_weights_14_3, ivec2(pos), 0).x)
  83. PL(5): [ 26] const float _const_15_3 = 64.00000000000000000000;
  84. PL(5): [ 27] const float _const_16_3 = 64.00000000000000000000;
  85. PL(5): [ 28] const float _const_17_3 = 1.00000000000000000000;
  86. PL(5): [ 29] vec4 _main_21_3() {
  87. PL(5): [ 30] // pl_shader_sample_ortho
  88. PL(5): [ 31] vec4 color = vec4(0.0);
  89. PL(5): [ 32] {
  90. PL(5): [ 33] vec2 pos = _tex_coord_1_3, size = _tex_size_2_3, pt = _tex_pt_3_3;
  91. PL(5): [ 34] vec2 dir = vec2(1.0, 0.0);
  92. PL(5): [ 35] pt *= dir;
  93. PL(5): [ 36] vec2 fcoord2 = fract(pos * size - vec2(0.5));
  94. PL(5): [ 37] float fcoord = dot(fcoord2, dir);
  95. PL(5): [ 38] vec2 base = pos - fcoord * pt - pt * vec2(3.0);
  96. PL(5): [ 39] float weight;
  97. PL(5): [ 40] vec4 ws, c;
  98. PL(5): [ 41] // scaler samples
  99. PL(5): [ 42] ws = _lut_4_3(vec2(0.00000000000000000000, fcoord));
  100. PL(5): [ 43] weight = ws[0];
  101. PL(5): [ 44] c = texture(_src_tex_0_3, base + pt * vec2(0.0));
  102. PL(5): [ 45] color[0] += weight * c[0];
  103. PL(5): [ 46] color[1] += weight * c[1];
  104. PL(5): [ 47] color[2] += weight * c[2];
  105. PL(5): [ 48] weight = ws[1];
  106. PL(5): [ 49] c = texture(_src_tex_0_3, base + pt * vec2(1.0));
  107. PL(5): [ 50] color[0] += weight * c[0];
  108. PL(5): [ 51] color[1] += weight * c[1];
  109. PL(5): [ 52] color[2] += weight * c[2];
  110. PL(5): [ 53] weight = ws[2];
  111. PL(5): [ 54] c = texture(_src_tex_0_3, base + pt * vec2(2.0));
  112. PL(5): [ 55] color[0] += weight * c[0];
  113. PL(5): [ 56] color[1] += weight * c[1];
  114. PL(5): [ 57] color[2] += weight * c[2];
  115. PL(5): [ 58] weight = ws[3];
  116. PL(5): [ 59] c = texture(_src_tex_0_3, base + pt * vec2(3.0));
  117. PL(5): [ 60] color[0] += weight * c[0];
  118. PL(5): [ 61] color[1] += weight * c[1];
  119. PL(5): [ 62] color[2] += weight * c[2];
  120. PL(5): [ 63] ws = _lut_4_3(vec2(1.00000000000000000000, fcoord));
  121. PL(5): [ 64] weight = ws[0];
  122. PL(5): [ 65] c = texture(_src_tex_0_3, base + pt * vec2(4.0));
  123. PL(5): [ 66] color[0] += weight * c[0];
  124. PL(5): [ 67] color[1] += weight * c[1];
  125. PL(5): [ 68] color[2] += weight * c[2];
  126. PL(5): [ 69] weight = ws[1];
  127. PL(5): [ 70] c = texture(_src_tex_0_3, base + pt * vec2(5.0));
  128. PL(5): [ 71] color[0] += weight * c[0];
  129. PL(5): [ 72] color[1] += weight * c[1];
  130. PL(5): [ 73] color[2] += weight * c[2];
  131. PL(5): [ 74] weight = ws[2];
  132. PL(5): [ 75] c = texture(_src_tex_0_3, base + pt * vec2(6.0));
  133. PL(5): [ 76] color[0] += weight * c[0];
  134. PL(5): [ 77] color[1] += weight * c[1];
  135. PL(5): [ 78] color[2] += weight * c[2];
  136. PL(5): [ 79] weight = ws[3];
  137. PL(5): [ 80] c = texture(_src_tex_0_3, base + pt * vec2(7.0));
  138. PL(5): [ 81] color[0] += weight * c[0];
  139. PL(5): [ 82] color[1] += weight * c[1];
  140. PL(5): [ 83] color[2] += weight * c[2];
  141. PL(5): [ 84] color *= vec4(_const_12_3);
  142. PL(5): [ 85] color.a = 1.0;
  143. PL(5): [ 86] }
  144. PL(5): [ 87] // pl_shader_delinearize
  145. PL(5): [ 88] color.rgb = max(color.rgb, 0.0);
  146. PL(5): [ 89] color.rgb *= vec3(1.0/49.26108374384236298501);
  147. PL(5): [ 90] color.rgb = pow(color.rgb, vec3(0.15930175781250000000));
  148. PL(5): [ 91] color.rgb = (vec3(0.83593750000000000000) + vec3(18.85156250000000000000) * color.rgb)
  149. PL(5): [ 92] / (vec3(1.0) + vec3(18.68750000000000000000) * color.rgb);
  150. PL(5): [ 93] color.rgb = pow(color.rgb, vec3(78.84375000000000000000));
  151. PL(5): [ 94] // pl_shader_encode_color
  152. PL(5): [ 95] {
  153. PL(5): [ 96] }
  154. PL(5): [ 97] // pl_shader_dither
  155. PL(5): [ 98] {
  156. PL(5): [ 99] float bias;
  157. PL(5): [100] vec2 pos = fract(gl_FragCoord.xy * 1.0/_const_15_3);
  158. PL(5): [101] bias = _lut_13_3(ivec2(pos * _const_16_3));
  159. PL(5): [102] color = vec4(1023.0) * color + vec4(bias);
  160. PL(5): [103] color = floor(color) * vec4(1.0 / 1023.0);
  161. PL(5): [104] }
  162. PL(5): [105] color *= vec4(1.0 / _const_17_3);
  163. PL(5): [106] vec4 _orig_color_18_3 = color;
  164. PL(5): [107] color = vec4(0.0, 0.0, 0.0, 1.0);
  165. PL(5): [108] color[0] = _orig_color_18_3[0];
  166. PL(5): [109] color[1] = _orig_color_18_3[1];
  167. PL(5): [110] color[2] = _orig_color_18_3[2];
  168. PL(5): [111] return color;
  169. PL(5): [112] }
  170. PL(5): [113]
  171. PL(5): [114] void main() {
  172. PL(5): [115] out_color = _main_21_3();
  173. PL(5): [116] }
  174. PL(5): fragment shader GLSL source:
  175. PL(5): [ 1] #version 450
  176. PL(5): [ 2] #extension GL_ARB_uniform_buffer_object : enable
  177. PL(5): [ 3] #extension GL_ARB_texture_gather : enable
  178. PL(5): [ 4] layout(binding=0) uniform sampler2D _osd_tex_0_0;
  179. PL(5): [ 5] layout(std140, binding=1) uniform _UBO_12_0 {
  180. PL(5): [ 6] layout(offset=0) mat3 _cms_matrix_10_0;
  181. PL(5): [ 7] };
  182. PL(5): [ 8] layout(location=1) in vec2 coord;
  183. PL(5): [ 9] layout(location=0) out vec4 out_color;
  184. PL(5): [ 10]
  185. PL(5): [ 11] const float _const_1_0 = 0.05958483740687370300;
  186. PL(5): [ 12] const float _const_2_0 = 0.87031054496765136718;
  187. PL(5): [ 13] const float _const_3_0 = 0.25000000000000000000;
  188. PL(5): [ 14] const float _const_4_0 = 1.00000000000000000000;
  189. PL(5): [ 15] const float _dst_range_5_0 = 4.92608356475830078125;
  190. PL(5): [ 16] const float _src_floor_6_0 = 0.00100000004749745130;
  191. PL(5): [ 17] const float _dst_peak_7_0 = 4.92610836029052734375;
  192. PL(5): [ 18] const float _dst_floor_8_0 = 0.00002463054079271387;
  193. PL(5): [ 19] const float _const_9_0 = 1.00000000000000000000;
  194. PL(5): [ 20] vec4 _main_13_0() {
  195. PL(5): [ 21] // overlay
  196. PL(5): [ 22] vec4 color = texture(_osd_tex_0_0, coord);
  197. PL(5): [ 23] // pl_shader_decode_color
  198. PL(5): [ 24] {
  199. PL(5): [ 25] }
  200. PL(5): [ 26] // pl_shader_color_map
  201. PL(5): [ 27] {
  202. PL(5): [ 28] // pl_shader_decode_color
  203. PL(5): [ 29] {
  204. PL(5): [ 30] }
  205. PL(5): [ 31] // pl_shader_linearize
  206. PL(5): [ 32] color.rgb = max(color.rgb, 0.0);
  207. PL(5): [ 33] color.rgb = vec3(_const_2_0) * pow(color.rgb + vec3(_const_1_0), vec3(2.4));
  208. PL(5): [ 34] // pl_shader_tone_map
  209. PL(5): [ 35] {
  210. PL(5): [ 36] float sig_peak = _const_4_0;
  211. PL(5): [ 37] float sig_avg = _const_3_0;
  212. PL(5): [ 38] color.rgb = vec3(1.0/_dst_range_5_0) * (color.rgb - vec3(_src_floor_6_0));
  213. PL(5): [ 39] sig_peak = (sig_peak - _src_floor_6_0) / _dst_range_5_0;
  214. PL(5): [ 40] vec3 sig = clamp(color.rgb, 0.0, sig_peak);
  215. PL(5): [ 41] vec3 sig_orig = color.rgb;
  216. PL(5): [ 42] sig *= min(_const_9_0 / sig_peak, 1.0);
  217. PL(5): [ 43] color.rgb = sig;
  218. PL(5): [ 44] color.rgb = vec3(_dst_range_5_0) * color.rgb + vec3(_dst_floor_8_0);
  219. PL(5): [ 45] }
  220. PL(5): [ 46] color.rgb = _cms_matrix_10_0 * color.rgb;
  221. PL(5): [ 47] // pl_shader_delinearize
  222. PL(5): [ 48] color.rgb = max(color.rgb, 0.0);
  223. PL(5): [ 49] color.rgb *= vec3(1.0/49.26108374384236298501);
  224. PL(5): [ 50] color.rgb = pow(color.rgb, vec3(0.15930175781250000000));
  225. PL(5): [ 51] color.rgb = (vec3(0.83593750000000000000) + vec3(18.85156250000000000000) * color.rgb)
  226. PL(5): [ 52] / (vec3(1.0) + vec3(18.68750000000000000000) * color.rgb);
  227. PL(5): [ 53] color.rgb = pow(color.rgb, vec3(78.84375000000000000000));
  228. PL(5): [ 54] // pl_shader_encode_color
  229. PL(5): [ 55] {
  230. PL(5): [ 56] }
  231. PL(5): [ 57] }
  232. PL(5): [ 58] // pl_shader_encode_color
  233. PL(5): [ 59] {
  234. PL(5): [ 60] }
  235. PL(5): [ 61] vec4 _orig_color_11_0 = color;
  236. PL(5): [ 62] color = vec4(0.0, 0.0, 0.0, 1.0);
  237. PL(5): [ 63] color[0] = _orig_color_11_0[0];
  238. PL(5): [ 64] color[1] = _orig_color_11_0[1];
  239. PL(5): [ 65] color[2] = _orig_color_11_0[2];
  240. PL(5): [ 66] color.a = _orig_color_11_0.a;
  241. PL(5): [ 67] return color;
  242. PL(5): [ 68] }
  243. PL(5): [ 69]
  244. PL(5): [ 70] void main() {
  245. PL(5): [ 71] out_color = _main_13_0();
  246. PL(5): [ 72] }
Advertisement
Add Comment
Please, Sign In to add comment