Advertisement
BDuck

Untitled

Nov 19th, 2018
706
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.09 KB | None | 0 0
  1. import vapoursynth as vs
  2. import sgvsfunc as sgf
  3.  
  4. core = vs.get_core()
  5.  
  6. source = core.dgdecodenv.DGSource(r"00800.dgi")
  7. source = core.std.Crop(source, top=32, bottom=34)
  8.  
  9. # Global Fix
  10. src = core.fb.FillBorders(source, top=1, mode="fillmargins")
  11. src = sgf.bbmod(src, 2, 0, 0, 0)
  12.  
  13. # Intro - Dirty Edge
  14. intro = core.std.Crop(src, top=104, bottom=104)
  15. intro = core.fb.FillBorders(intro, top=1, mode="fillmargins")
  16. intro = sgf.bbmod(intro, 2, 0, 0, 0, blur=100)
  17. intro = core.std.AddBorders(intro, top=104, bottom=104)
  18.  
  19. # IMAX - Deband
  20. imax_db = core.f3kdb.Deband(src, y=60, grainy=45, dynamic_grain=True)
  21.  
  22. # Non-IMAX - Deband
  23. non_imax_db = core.f3kdb.Deband(src, y=60, grainy=45, dynamic_grain=True)
  24. non_imax_db = core.std.Crop(non_imax_db, top=104, bottom=104)
  25. non_imax_db = core.std.AddBorders(non_imax_db, top=104, bottom=104)
  26.  
  27. # Merge
  28. output = sgf.ReplaceFrames(src, intro, avs_filename=r'intro.txt')
  29. output = sgf.ReplaceFrames(output, imax_db, avs_filename=r'deband_IMAX.txt')
  30. output = sgf.ReplaceFrames(output, non_imax_db, avs_filename=r'deband.txt')
  31.  
  32. # Output
  33. output.set_output()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement