Advertisement
mawen1250

GrainStabilizeMC v0.4

Nov 24th, 2012
352
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Avisynth 16.22 KB | None | 0 0
  1. ###### GrainStabilizeMC v0.4 ######   by mawen1250   ######  2012.11.25  ######
  2. ###### Requirements: masktools v2.0a48, mvtools v2.6.0.5, dither v1.21.0 ######
  3. ###### RemoveGrain v1.0pre                                               ######
  4.  
  5. Function GSMC(clip input, clip "p", clip "Lmaskl", string "Preset", int "nrmode", int "radius", int "adapt", int "rep",
  6. \ int "Y", int "U", int "V", bool "lsb_in", bool "lsb", bool "lsb_out", int "dither",
  7. \ bool "chromamv", int "blksize", int "overlap", int "thSAD", int "thSADC", int "thSCD1", int "thSCD2", int "limit", int "limitc",
  8. \ bool "truemotion", bool "MVglobal", int "pel", int "pelsearch", int "search", int "searchparam", int "MVsharp", int "DCT")
  9. {
  10.  
  11.   nrmode   = Default(nrmode, 1      )
  12.   # Mode to get grain/noise from input clip:
  13.   # 1: 3x3 Average Blur on luma, 3x3 Gaussian Blur on chroma,
  14.   # 2: 3x3 Min Blur,  3: 5x5 Min Blur,  4: 7x7 Min Blur.
  15.   # or define your own denoise clip "p".
  16.  
  17.   radius   = Default(radius, 1      )
  18.   # Temporal radius of MDegrain for grain stabilize.(1-3)
  19.  
  20.   adapt    = Default(adapt,  64     )
  21.   # Threshold for luma-adaptative mask
  22.   # -1: off,  0: source,  255: invert.
  23.   # or define your own luma mask clip "Lmaskl".
  24.  
  25.   rep      = Default(rep,    13     )
  26.   # Mode of repair to avoid artifacts, set 0 to turn off this operation.
  27.  
  28.   Y        = Default(Y,      3      )
  29.   U        = Default(U,      2      )
  30.   V        = Default(V,      2      )
  31.  
  32.   Y        = max(min(Y, 3), 1)
  33.   U        = max(min(U, 3), 1)
  34.   V        = max(min(V, 3), 1)
  35.   Yt       = Y == 3
  36.   Ut       = U == 3
  37.   Vt       = V == 3
  38.   Y31      = Yt ? 3 : 1
  39.   U31      = Ut ? 3 : 1
  40.   V31      = Vt ? 3 : 1
  41.   Y321     = Y <= 1 ? 1 : 3
  42.   U321     = U <= 1 ? 1 : 3
  43.   V321     = V <= 1 ? 1 : 3
  44.   Y421     = Y == 3 ? 4 : Y
  45.   U421     = U == 3 ? 4 : U
  46.   V421     = V == 3 ? 4 : V
  47.  
  48.   Assert( nrmode>=1 && nrmode<=4,  "GrainStabilizeMC: invalid value for nrmode(1~4)!"   )
  49.   Assert( radius>=1 && radius<=3,  "GrainStabilizeMC: invalid value for radius(1~3)!"   )
  50.   Assert( adapt>=-1 && adapt<=255, "GrainStabilizeMC: invalid value for adapt(-1~255)!" )
  51.  
  52.   lsb_in   = Default(lsb_in, false  )   # input      clip is 16-bit stacked or not
  53.   lsb      = Default(lsb,    false  )   # processing clip is 16-bit stacked or not
  54.   lsb_out  = Default(lsb_out,lsb    )   # output     clip is 16-bit stacked or not
  55.   dither   = Default(dither, 6      )   # dither mode for 16-bit to 8-bit conversion
  56.  
  57.   sw       = input.width
  58.   sh       = input.height
  59.   sh       = lsb_in ? sh/2 : sh
  60.   HD       = (sw > 1024 || sh > 576) ? true : false
  61.  
  62.   Preset   = Default(Preset, "Faster")
  63.  
  64.   pnum     = preset == "Very Fast" ?  0
  65.   \        : preset == "Faster"    ?  1
  66.   \        : preset == "Fast"      ?  2
  67.   \        : preset == "Medium"    ?  3
  68.   \        : preset == "Slow"      ?  4
  69.   \        : preset == "Slower"    ?  5
  70.   \        : preset == "Very Slow" ?  6
  71.   \        :                          7
  72.   Assert( pnum<=6, """GrainStabilizeMC: Unknown Preset!
  73.  Allowed Preset: "Very Fast","Faster","Fast","Medium","Slow","Slower","Very Slow".""" )
  74.  
  75.   # Preset groups:                                 Very Fast     Fast          Slow          Very Slow
  76.   # Preset groups:                                        Faster        Medium        Slower
  77.  
  78.   bs          = HD ? 16 :  8
  79.   bs2         = HD ? 32 : 16
  80.   chromamv    = Default(chromamv,    Ut || Vt    )
  81.   blksize     = Default(blksize,     Select(pnum,  bs2,   bs2,   bs2,   bs,    bs,    bs,    bs    ))
  82.   ol          = blksize/2
  83.   ol2         = blksize/4
  84.   overlap     = Default(overlap,     Select(pnum,  ol2,   ol2,   ol2,   ol,    ol,    ol,    ol    ))
  85.   thSAD       = Default(thSAD,       300         )
  86.   thSADC      = Default(thSADC,      thSAD/2     )
  87.   thSCD1      = Default(thSCD1,      300         )
  88.   thSCD2      = Default(thSCD2,      100         )
  89.   truemotion  = Default(truemotion,  false       )
  90.   MVglobal    = Default(MVglobal,    false       )
  91.   pel         = Default(pel,         Select(pnum,  1,     1,     2,     2,     2,     2,     2     ))
  92.   pelsearch   = Default(pelsearch,   Select(pnum,  1,     2,     2,     1,     2,     2,     2     ))
  93.   search      = Default(search,      Select(pnum,  2,     4,     4,     2,     2,     4,     5     ))
  94.   searchparam = Default(searchparam, Select(pnum,  1,     2,     2,     2,     2,     2,     2     ))
  95.   MVsharp     = Default(MVsharp,     2           )
  96.   DCT         = Default(DCT,         0           )
  97.  
  98.   Umv      = chromamv ? 3 : U31
  99.   Vmv      = chromamv ? 3 : V31
  100.   plane    = !Yt ? !Ut ? 2 : !Vt ? 1 : 3 : !Ut&&!Vt ? 0 : 4
  101.  
  102.  
  103.  
  104.   input8   = !lsb_in ? input : input.DitherPost(Y=3, U=lsb?1:U321, V=lsb?1:V321, mode=dither)
  105.   input16  =  lsb_in ? input : input.Dither_convert_8_to_16
  106.  
  107.   plsb_in  = Defined(p) ? input.height == p.height ? lsb_in : !lsb_in : lsb_in
  108.   iresc    = Defined(p) ? plsb_in == lsb_in ? input.height == p.height ? true : false
  109.   \                                         : lsb_in == false ? input.height*2 == p.height ? true : false
  110.   \                                                           : input.height == p.height*2 ? true : false
  111.   \                     : true
  112.   Assert( iresc == true, """GrainStabilizeMC: clip "input" and clip "p" resolution not match!
  113.  (GSMC have already considered different condition of lsb)""" )
  114.  
  115.   p8       = Defined(p) ? !plsb_in ? p : p.DitherPost(Y=3, U=Umv, V=Vmv, mode=0) : NOP()
  116.   p16      = Defined(p) ?  plsb_in ? p : p.Dither_convert_8_to_16 : NOP()
  117.  
  118.   pre_nr8  = !lsb ? Defined(p) ? p8  
  119.   \                            : nrmode == 1 ? input8 .RemoveGrain(Yt?20:0, Ut?11:0, Vt?11:0)
  120.   \                                          : input8 .GSMC_MinBlur(nrmode-1, Ut||Vt?3:2)
  121.   \               : NOP()
  122.   dif_nr8  = !lsb ? mt_makediff(input8, pre_nr8, Y=Y31, U=U31, V=V31) : NOP()
  123.  
  124.   pre_nr16 =  lsb ? Defined(p) ? p16
  125.   \                            : nrmode == 1 ? input16.Dither_removegrain16(Yt?20:0, Ut?11:0, Vt?11:0)
  126.   \                                          : input16.GSMC_MinBlur16(nrmode-1, Ut||Vt?3:2)
  127.   \               : NOP()
  128.   dif_nr16 =  lsb ? Dither_sub16(input16, pre_nr16, Y=Y31, U=U31, V=V31, dif=true) : NOP()
  129.  
  130.   pre_nr   = Defined(p) ? p8 : lsb ? pre_nr16.DitherPost(Y=3  , U=Umv, V=Vmv, mode=0) : pre_nr8
  131.   dif_nr   =  lsb ? dif_nr16.DitherPost(Y=Y31, U=U31, V=V31, mode=dither) : dif_nr8
  132.  
  133.   psuper   = pre_nr.MSuper(pel=pel, levels=0, sharp=MVsharp, chroma=chromamv)
  134.   difsuper = dif_nr.MSuper(pel=pel, levels=1, sharp=MVsharp, chroma=Ut || Vt)
  135.  
  136.   fv3      = radius>=3 ? psuper.MAnalyse(isb=false, delta=3, truemotion=truemotion, blksize=blksize, overlap=overlap, pelsearch=pelsearch, search=search, searchparam=searchparam, DCT=DCT, global=MVglobal, chroma=chromamv) : NOP()
  137.   fv2      = radius>=2 ? psuper.MAnalyse(isb=false, delta=2, truemotion=truemotion, blksize=blksize, overlap=overlap, pelsearch=pelsearch, search=search, searchparam=searchparam, DCT=DCT, global=MVglobal, chroma=chromamv) : NOP()
  138.   fv1      = radius>=1 ? psuper.MAnalyse(isb=false, delta=1, truemotion=truemotion, blksize=blksize, overlap=overlap, pelsearch=pelsearch, search=search, searchparam=searchparam, DCT=DCT, global=MVglobal, chroma=chromamv) : NOP()
  139.   bv1      = radius>=1 ? psuper.MAnalyse(isb=true,  delta=1, truemotion=truemotion, blksize=blksize, overlap=overlap, pelsearch=pelsearch, search=search, searchparam=searchparam, DCT=DCT, global=MVglobal, chroma=chromamv) : NOP()
  140.   bv2      = radius>=2 ? psuper.MAnalyse(isb=true,  delta=2, truemotion=truemotion, blksize=blksize, overlap=overlap, pelsearch=pelsearch, search=search, searchparam=searchparam, DCT=DCT, global=MVglobal, chroma=chromamv) : NOP()
  141.   bv3      = radius>=3 ? psuper.MAnalyse(isb=true,  delta=3, truemotion=truemotion, blksize=blksize, overlap=overlap, pelsearch=pelsearch, search=search, searchparam=searchparam, DCT=DCT, global=MVglobal, chroma=chromamv) : NOP()
  142.  
  143.   dif_sb   = radius==1 ? dif_nr.MDegrain1(difsuper, bv1, fv1                    , thSAD=thSAD, thSADC=thSADC, thSCD1=thSCD1, thSCD2=thSCD2, limit=limit, limitc=limitc, plane=plane, lsb=lsb)
  144.   \        : radius==2 ? dif_nr.MDegrain2(difsuper, bv1, fv1, bv2, fv2          , thSAD=thSAD, thSADC=thSADC, thSCD1=thSCD1, thSCD2=thSCD2, limit=limit, limitc=limitc, plane=plane, lsb=lsb)
  145.   \        :             dif_nr.MDegrain3(difsuper, bv1, fv1, bv2, fv2, bv3, fv3, thSAD=thSAD, thSADC=thSADC, thSCD1=thSCD1, thSCD2=thSCD2, limit=limit, limitc=limitc, plane=plane, lsb=lsb)
  146.  
  147.   Lmaskl   = Defined(Lmaskl) ? Lmaskl
  148.   \        : adapt == -1     ? NOP()
  149.   \        : adapt == 0      ? input8.RemoveGrain(19, -1)
  150.   \        : adapt == 255    ? input8.mt_invert(U=1, V=1).RemoveGrain(19, -1)
  151.   \        :                   input8.mt_lut("x "+string(adapt)+" - abs 255 * "+string(adapt)+" 128 - abs 128 + /", U=1, V=1).RemoveGrain(19, -1)
  152.   Lmask    = adapt == -1     ? NOP() : Ut || Vt  ? Lmaskl.GSMC_YtoYUV : Lmaskl
  153.  
  154.   stable8  = !lsb ? mt_adddiff(pre_nr8, dif_sb, Y=Y31, U=U31, V=V31) : NOP()
  155.   stable8  = !lsb ? rep   ==  0 ? stable8  : stable8.Repair(input8, Yt?rep:-1, Ut?rep:-1, Vt?rep:-1) : NOP()
  156.   mL8      = !lsb ? adapt == -1 ? mt_lutxy(input8, stable8, Y=Y421, U=U421, V=V421)  
  157.   \                             : mt_merge(input8, stable8, Lmask, luma=false, Y=Y, U=U, V=V) : NOP()
  158.  
  159.   stable16 =  lsb ? Dither_add16(pre_nr16, dif_sb, Y=Y31, U=U31, V=V31, dif=true) : NOP()
  160.   stable16 =  lsb ? rep   ==  0 ? stable16 : stable16.Dither_repair16(input16, Yt?rep:-1, Ut?rep:-1, Vt?rep:-1) : NOP()
  161.   mL16     =  lsb ? adapt == -1 ? mt_lutxy(input16, stable16, Y=Y421, U=U421, V=V421)
  162.   \                             : Dither_merge16_8(input16, stable16, Lmask, luma=false, Y=Y, U=U, V=V) : NOP()
  163.  
  164.   end      = lsb_out ? lsb ? mL16
  165.   \                        : mL8.Dither_convert_8_to_16
  166.   \                  : lsb ? mL16.DitherPost(Y=Y321, U=U321, V=V321, mode=dither)
  167.   \                        : mL8
  168.  
  169.   return end
  170.  
  171. }
  172.  
  173.  
  174. Function GSMC_YtoYUV(clip inputl, string "colorspace")
  175. {
  176.  sw          = inputl.width
  177.  sh          = inputl.height
  178.  wmod4       = (sw/4*4==sw) ? true : false
  179.  hmod4       = (sh/4*4==sh) ? true : false
  180.  
  181.  icolorspace = inputl.YtoYUV_GetCSP
  182.  ocolorspace = Defined(colorspace) ? colorspace : icolorspace
  183.  
  184.  try {
  185.    inputp = inputl.ConvertToY8
  186.    inputc = ocolorspace == "YV24" ? inputp
  187.    \      : ocolorspace == "YV16" ? inputp.BicubicResize(sw/2, sh  , -0.50)
  188.    \      :                         inputp.BicubicResize(sw/2, sh/2, -0.50)
  189.    
  190.    output = YtoUV(inputc, inputc, inputp)
  191.  
  192.  } catch ( error_msg ) {
  193.    inputp = wmod4&&hmod4 ? inputl : inputl.PointResize(wmod4?sw:sw+2, hmod4?sh:sh+2, 0, 0, wmod4?sw:sw+2, hmod4?sh:sh+2)
  194.    inputc = inputp.BicubicResize(sw/2, sh/2, -0.50)
  195.    
  196.    output = YtoUV(inputc, inputc, inputp)
  197.    output = wmod4&&hmod4 ? output : output.Crop(0, 0, wmod4?0:-2, hmod4?0:-2)
  198.  
  199.  }
  200.  
  201.  return output
  202.  
  203.  Function YtoYUV_GetCSP(clip c) {
  204.    return c.IsPlanar ? c.IsYV12 ? "YV12" :
  205.    \                   c.IsYV16 ? "YV16" :
  206.    \                   c.IsYV24 ? "YV24" : c.GetCSP_Y8_YV411 :
  207.    \      c.IsYUY2   ? "YUY2"   :
  208.    \      c.IsRGB32  ? "RGB32"  :
  209.    \      c.IsRGB24  ? "RGB24"  : "Unknown"
  210.  
  211.    Function GetCSP_Y8_YV411(clip c) {
  212.      try {
  213.        c.UtoY
  214.        csp = "YV411"
  215.      } catch ( error_msg ) {
  216.       csp = "Y8"
  217.      }
  218.      return csp
  219.    }
  220.  }
  221. }
  222.  
  223.  
  224. Function GSMC_MinBlur(clip clp, int "r", int "uv"){
  225.  
  226. r     = Default(r,  1)
  227. uv    = Default(uv, 3)
  228.  
  229. uv2   = (uv==2) ? 1  : uv
  230. rg4   = (uv==3) ? 4  : -1
  231. rg11  = (uv==3) ? 11 : -1
  232. rg20  = (uv==3) ? 20 : -1
  233. medf  = (uv==3) ? 1  : -200
  234. uvm2  = (r==2)  ? (uv==3?3:uv==2?0:-1) : nop()
  235. uvm3  = (r==3)  ? (uv==3?3:uv==2?0:-1) : nop()
  236.  
  237. RG11D = (r<=0) ? mt_makediff(clp, clp.MinBlur_sbr(uv=uv2  ), U=uv2, V=uv2)
  238. \     : (r==1) ? mt_makediff(clp, clp.RemoveGrain(11, rg11), U=uv2, V=uv2)
  239. \     : (r==2) ? mt_makediff(clp, clp.RemoveGrain(11, rg11).RemoveGrain(20, rg20), U=uv2, V=uv2)
  240. \     :          mt_makediff(clp, clp.RemoveGrain(11, rg11).RemoveGrain(20, rg20).RemoveGrain(20, rg20), U=uv2, V=uv2)
  241. RG4D  = (r<=1) ? mt_makediff(clp, clp.RemoveGrain(4,  rg4 ), U=uv2, V=uv2)
  242. \     : (r==2) ? mt_makediff(clp, clp.Quantile(radius_y=2, radius_u=uvm2, radius_v=uvm2), U=uv2, V=uv2)
  243. \     :          mt_makediff(clp, clp.Quantile(radius_y=3, radius_u=uvm3, radius_v=uvm3), U=uv2, V=uv2)
  244.  
  245. DD    = mt_lutxy(RG11D, RG4D, "x 128 - y 128 - * 0 < 128 x 128 - abs y 128 - abs < x y ? ?", U=uv2, V=uv2)
  246.  
  247. return clp.mt_makediff(DD, U=uv, V=uv)
  248.  
  249.  
  250.   Function MinBlur_sbr(clip c, int "uv") {
  251.   uv     = Default(uv, 1)
  252.   uv2    = (uv==2) ? 1  : uv
  253.   rg11   = (uv==3) ? 11 : -1
  254.   rg11D  = mt_makediff(c, c.RemoveGrain(11, rg11), U=uv2, V=uv2)
  255.   rg11DD = mt_lutxy(rg11D, rg11D.RemoveGrain(11, rg11), "x y - x 128 - * 0 < 128 x y - abs x 128 - abs < x y - 128 + x ? ?", U=uv2, V=uv2)
  256.  
  257.   return c.mt_makediff(rg11DD, U=uv, V=uv)
  258.   }
  259. }
  260.  
  261.  
  262. Function GSMC_MinBlur16(clip clp, int "mode", int "uv"){
  263.  
  264. mode  = Default(mode, 1)
  265. uv    = Default(uv,   3)
  266.  
  267. uv2   = (uv==2) ? 1  : uv
  268. rg4   = (uv==3) ? 4  : -1
  269. rg11  = (uv==3) ? 11 : -1
  270. rg20  = (uv==3) ? 20 : -1
  271.  
  272. RG11D = (mode<=1) ? Dither_sub16(clp, clp.Dither_removegrain16(11, rg11), U=uv2, V=uv2, dif=true)
  273. \     : (mode==2) ? Dither_sub16(clp, clp.Dither_removegrain16(20, rg20), U=uv2, V=uv2, dif=true)
  274. \     : (mode==3) ? Dither_sub16(clp, clp.MinBlur16_sbr16     (uv=uv2  ), U=uv2, V=uv2, dif=true)
  275. \     : (mode==4) ? Dither_sub16(clp, clp.Dither_removegrain16(11, rg11).Dither_removegrain16(20, rg20), U=uv2, V=uv2, dif=true)
  276. \     :             Dither_sub16(clp, clp.Dither_removegrain16(11, rg11).Dither_removegrain16(20, rg20)
  277. \                                        .Dither_removegrain16(20, rg20), U=uv2, V=uv2, dif=true)
  278. RG4D  = (mode<=3) ? Dither_sub16(clp, clp.Dither_removegrain16(4,  rg4 ), U=uv2, V=uv2, dif=true)
  279. \     : (mode==4) ? Dither_sub16(clp, clp.Dither_median16(2, 2, 0, U=uv2, V=uv2), U=uv2, V=uv2, dif=true)
  280. \     :             Dither_sub16(clp, clp.Dither_median16(3, 3, 0, U=uv2, V=uv2), U=uv2, V=uv2, dif=true)
  281.  
  282. DD    = MinBlur16_limitdiff16(RG11D, RG4D, U=uv2, V=uv2)
  283.  
  284. return clp.Dither_sub16(DD, U=uv, V=uv, dif=true)
  285.  
  286.  
  287.   Function MinBlur16_sbr16(clip clp, int "uv") {
  288.   uv       = Default(uv, 1)
  289.   uv2      = (uv==2) ? 1  : uv
  290.   rg11     = (uv==3) ? 11 : -1
  291.  
  292.   rg11D    = Dither_sub16(clp, clp.Dither_removegrain16(11, rg11), U=uv2, V=uv2, dif=true)
  293.   rg11Dr   = rg11D.Dither_removegrain16(11, rg11)
  294.  
  295.   abrg11D  = rg11D.Dither_lut16("x 32768 - abs", U=uv2, V=uv2)
  296.   Ddiff    = Dither_sub16(rg11D, rg11Dr, U=uv2, V=uv2, dif=true)
  297.   abDdiff  = Ddiff.Dither_lut16("x 32768 - abs", U=uv2, V=uv2)
  298.   abDDD    = Dither_sub16(abDdiff, abrg11D, U=uv2, V=uv2, dif=true)
  299.  
  300.   Dmask1   = abDDD.Dither_lut16("x 32768 < 65535 0 ?", U=uv2, V=uv2)
  301.   Ddiffg   = Ddiff.Dither_lut16("x 32768 == x x 32768 < 0 65535 ? ?", U=uv2, V=uv2).Crop(0, 0, 0, -Ddiff.height()/2)
  302.   rg11Dg   = rg11D.Dither_lut16("x 32768 == x x 32768 < 0 65535 ? ?", U=uv2, V=uv2).Crop(0, 0, 0, -rg11D.height()/2)
  303.   Dmask2   = mt_lutxy(Ddiffg, rg11Dg, "x 128 - y 128 - * 0 < 0 255 ?", U=uv2, V=uv2)
  304.  
  305.   DD1      = Dither_merge16(rg11D, Ddiff, Dmask1, luma=false, U=uv2, V=uv2)
  306.   DD2      = Dither_merge16_8(DD1.MinBlur16_gen_null_diff(), DD1, Dmask2, luma=false, U=uv2, V=uv2)
  307.  
  308.   return clp.Dither_sub16(DD2, U=uv, V=uv, dif=true)
  309.   }
  310.  
  311.  
  312.   Function MinBlur16_limitdiff16(clip diff1, clip diff2, int "Y", int "U", int "V")
  313.   {
  314.   Y          = Default(Y,        3)
  315.   U          = Default(U,        3)
  316.   V          = Default(V,        3)
  317.  
  318.   abdiff1    = Dither_lut16(diff1, "x 32768 - abs", Y=Y==3?3:1, U=U==3?3:1, V=V==3?3:1)
  319.   abdiff2    = Dither_lut16(diff2, "x 32768 - abs", Y=Y==3?3:1, U=U==3?3:1, V=V==3?3:1)
  320.   abdiffdiff = Dither_sub16(abdiff1, abdiff2, Y=Y==3?3:1, U=U==3?3:1, V=V==3?3:1, dif=true)
  321.   bin        = Dither_lut16(abdiffdiff, "x 32768 <= 0 65535 ?", Y=Y==3?3:1, U=U==3?3:1, V=V==3?3:1)
  322.  
  323.   return Dither_merge16(diff1, diff2, bin, luma=false, Y=Y, U=U, V=V)
  324.   }
  325.  
  326.  
  327.   Function MinBlur16_gen_null_diff(clip input, bool "lsb_in")
  328.   {
  329.   lsb_in = Default(lsb_in, true)
  330.    
  331.   vers   = VersionNumber ()
  332.   p_t    = (vers < 2.60) ? "YV12" : Dither_undef ()
  333.    
  334.   input    = lsb_in ? input.Crop(0, 0, 0, -input.height/2) : input
  335.    
  336.   StackVertical(BlankClip(input, pixel_type=p_t, color_yuv=8421504), BlankClip(input, pixel_type=p_t, color_yuv=0))
  337.   }
  338. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement