View difference between Paste ID: b5PweecB and JVBtB6X5
SHOW: | | - or go back to the newest paste.
1
# Y'et A'nother H'alo R'educing script
2
3
function YAHR(clip clp)
4
{
5
b1    = clp.minblur(2).removegrain(11,-1)
6
b1D   = mt_makediff(clp,b1)
7
w1    = clp.aWarpSharp(depth=32,blurlevel=2,thresh=0.5)
8
w1b1  = w1.minblur(2,1).removegrain(11,-1)
9
w1b1D = mt_makediff(w1,w1b1)
10
DD    = b1D.repair(w1b1D,13) 
11
DD2   = mt_makediff(b1D,DD)
12
clp.mt_makediff(DD2,U=2,V=2)
13
}
14
15
# Y'et A'nother H'alo R'educing script
16-
# YAHR A.SONY mod 1.35 , original YAHR was by Didée
16+
# YAHR A.SONY mod 1.37 , original YAHR was by Didée
17
# good deHalo for modern DVD and other cases
18
19-
function YAHR2(clip clp, int "depth", int "blur", bool "awarp4")
19+
function YAHR2(clip clp, int "depth", int "blur", bool "useawarp4")
20
{
21
22
depth         = Default(depth, 8)
23-
awarp4        = Default(awarp4, false)
23+
useawarp4     = Default(useawarp4, false)
24
25
b1    = clp.minblur(2).removegrain(11,-1)
26
b1D   = mt_makediff(clp,b1)
27-
w1    = awarp4 ? clp.aWarpSharp4xx(depth=depth,blur=blur,chroma=1,awarp4=true) : clp.aWarpSharp2(depth=depth,blur=blur,chroma=1)
27+
w1    = useawarp4 ? clp.aWarpSharp4xx(depth=depth,blur=blur,chroma=1,useawarp4=true) : clp.aWarpSharp2(depth=depth,blur=blur,chroma=1)
28
w1b1  = w1.minblur(2,1).removegrain(11,-1)
29
w1b1D = mt_makediff(w1,w1b1)
30
DD    = b1D.repair(w1b1D,13) 
31
DD2   = mt_makediff(b1D,DD)
32
clp.mt_makediff(DD2,U=2,V=2)
33
}
34
35-
function YAHR3(clip src, int "depth", int "radius", int "blur", bool "awarp4")
35+
function YAHR3(clip src, int "depth", int "radius", int "blur", bool "useawarp4")
36
{
37
depth         = Default(depth, 32)
38
radius        = Default(radius, 6)
39
src
40
edgm = EMask_dhh(ColorYUV(autogain=true), 3, 140,true)
41-
hfil = YAHR2(depth=depth,blur=blur,awarp4=awarp4)
41+
hfil = YAHR2(depth=depth,blur=blur,useawarp4=useawarp4)
42
RM2  = DR_Radius_dhh(edgm.mt_inflate(),radius,0).mt_inflate()
43
DeRinging = mt_Merge(hfil, src, edgm.mt_inflate(155,155))
44
mt_Merge(src, DeRinging, RM2, u=2, v=2)
45
}