JKP123

Animation

Mar 24th, 2021
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.22 KB | None | 0 0
  1. import vapoursynth as vs
  2. core = vs.core
  3.  
  4. from vsTAAmbk import TAAmbk as taa
  5. import finedehalo as fd
  6. import mvsfunc as mvf
  7. #import lvsfunc as lvf
  8. import kagefunc as kgf
  9. import havsfunc as haf
  10. from vsutil import *
  11.  
  12. core.max_cache_size = 16*1024
  13.  
  14. # Source
  15.  
  16. src = core.lsmas.LWLibavSource("fichier.m2ts")
  17. src = depth(src, 16)
  18.  
  19. # Filtering
  20. denoise = mvf.BM3D(src, 1.5)
  21.  
  22. aa = taa(denoise, 3, opencl=True)
  23.  
  24. deband = join([
  25. core.placebo.Deband(plane(aa, 0), grain=0, threshold=2.8, radius=16),
  26. core.placebo.Deband(plane(aa, 1), grain=0, threshold=3.2, radius=20),
  27. core.placebo.Deband(plane(aa, 2), grain=0, threshold=3.2, radius=20)
  28. ])
  29.  
  30. dehalo = fd.fine_dehalo(deband)
  31. dering = haf.HQDeringmod(dehalo)
  32.  
  33. grain = kgf.adaptive_grain(dering, 0.35, luma_scaling=8)
  34.  
  35. # Output
  36. final = depth(grain, 8)
  37. final.set_output() 
  38.  
  39.  
  40. avec ensuite:
  41. @ECHO OFF
  42. setLocal EnableDelayedExpansion
  43.  
  44. echo Starting x264 8 bit encode
  45. echo.
  46.  
  47. set out=x264_8bit_encode.mp4
  48. set script="0001.vpy"
  49. set params=--crf 14 --preset slow --tune animation --aq-mode 3 --output-depth 8
  50.  
  51. VapourSynth64\vspipe.exe "%script%" - --y4m | "bin\x264.exe" --demuxer y4m %params% -o "%out%" -
  52. pause
  53.  
Advertisement
Add Comment
Please, Sign In to add comment