Welcome Guest ( Log In | Register )


Important

The forums will be closing permanently the weekend of March 15th. Please see the notice in the announcements forum for details.

 
I Need Some Help!
« Next Oldest | Next Newest » Track this topic | Email this topic | Print this topic
m00033000
Posted: Jan 8 2015, 07:45 PM


Newbie


Group: Members
Posts: 1
Member No.: 38532
Joined: 8-January 15



Hi, I am trying to use some filters, but I have had troubles...

I asked to a friend wich script he used in a video and he sent me this script:

MPEG2Source("dvd.d2v")
v0=last
checkmate.repair(last)
qtgmc(sourcematch=3,thsad1=100,thsad2=200,fpsdivisor=2)
lumayv12(int(16*float(245-24)/219-24),219.0/(245-24))
stabilize()
dfttestMCsimple(mc=1,sigma=2,lsb=true).f3kdb(grainy=30,grainc=0,input_mode=1)
crop(12,0,-12,0)
maa2()
dehalo()

function linemask( clip c, int "blur", int "thresh", int "str" )
{
blur=default(blur,5)
thresh=default(thresh,4)
str=default(str,16)
mt_lutxy(c,c.binomialblur(blur,u=1,v=1),"x "+string(thresh)+" + y < y x - "+string(str)+" * 0 ?")
}

function stabilizelines( clip c )
{
c.mt_merge(c.qtgmc(inputtype=1,sharpness=0,tr0=0),c.linemask(5,2,16).mt_expand.binomialblur(3,u=1,v=1),true)
}

function dehalo( clip c )
{
c
dehalo_alpha_mt(2,2,0,1).yahrmask(5,32)
dehalo_alpha_mt(3,3,0,1)
m=c.crop(0,360,0,0).tcolormask("$c0d169 $fdff7a $d2e944",30).mt_expand_multi(sw=3,sh=3).mt_inpand.mt_inpand.binomialblur(3,u=1,v=1)
overlay(c.crop(0,360,0,0),0,360,)
}



function dfttestMCsimple(clip input, int "mc", float "sigma", int "thSAD", bool "lsb")
{
mc = default(mc, 2).min(5)
tbsize = default(tbsize, mc * 2 + 1)
lsb=default(lsb,true)

super = MSuper(input)

# Motion vtor search.
b5v = MAnalyse(super, delta=5, isb=true)
b4v = MAnalyse(super, delta=4, isb=true)
b3v = MAnalyse(super, delta=3, isb=true)
b2v = MAnalyse(super, delta=2, isb=true)
b1v = MAnalyse(super, delta=1, isb=true)
f1v = MAnalyse(super, delta=1)
f2v = MAnalyse(super, delta=2)
f3v = MAnalyse(super, delta=3)
f4v = MAnalyse(super, delta=4)
f5v = MAnalyse(super, delta=5)

# Motion Compensation.
b5 = MCompensate(input, super, b5v, thSAD=thSAD)
b4 = MCompensate(input, super, b4v, thSAD=thSAD)
b3 = MCompensate(input, super, b3v, thSAD=thSAD)
b2 = MCompensate(input, super, b2v, thSAD=thSAD)
b1 = MCompensate(input, super, b1v, thSAD=thSAD)
f1 = MCompensate(input, super, f1v, thSAD=thSAD)
f2 = MCompensate(input, super, f2v, thSAD=thSAD)
f3 = MCompensate(input, super, f3v, thSAD=thSAD)
f4 = MCompensate(input, super, f4v, thSAD=thSAD)
f5 = MCompensate(input, super, f5v, thSAD=thSAD)

# Create compensated .
mc >= 5 ? Interleave(f5, f4, f3, f2, f1, input, b1, b2, b3, b4, b5) :
\ mc == 4 ? Interleave(f4, f3, f2, f1, input, b1, b2, b3, b4) :
\ mc == 3 ? Interleave(f3, f2, f1, input, b1, b2, b3) :
\ mc == 2 ? Interleave(f2, f1, input, b1, b2) :
\ Interleave(f1, input, b1)

# Perform dfttest.
dfttest(sigma=sigma, lsb=lsb)

SelectEvery(mc * 2 + 1, mc)
}

function MinBlur(clip clp, int r, int "uv")
{# Nifty Gauss/Median combination
uv = default(uv,3)
uv2 = (uv==2) ? 1 : uv
rg4 = (uv==3) ? 4 : -1
rg11 = (uv==3) ? 11 : -1
rg20 = (uv==3) ? 20 : -1
medf = (uv==3) ? 1 : -200

RG11D = (r==1) ? mt_makediff(clp,clp.removegrain(11,rg11),U=uv2,V=uv2)
\ : (r==2) ? mt_makediff(clp,clp.removegrain(11,rg11).removegrain(20,rg20),U=uv2,V=uv2)
\ : mt_makediff(clp,clp.removegrain(11,rg11).removegrain(20,rg20).removegrain(20,rg20),U=uv2,V=uv2)
RG4D = (r==1) ? mt_makediff(clp,clp.removegrain(4,rg4),U=uv2,V=uv2)
\ : (r==2) ? mt_makediff(clp,clp.medianblur(2,2*medf,2*medf),U=uv2,V=uv2)
\ : mt_makediff(clp,clp.medianblur(3,3*medf,3*medf),U=uv2,V=uv2)
DD = mt_lutxy(RG11D,RG4D,"x 128 - y 128 - * 0 < 128 x 128 - abs y 128 - abs < x y ? ?",U=uv2,V=uv2)
clp.mt_makediff(DD,U=uv,V=uv)
return(last)
}

function YAHR2( clip clp, int "warpdepth" )
{# Y'et A'nother H'alo R'educing script
warpdepth=default(warpdepth,32)
b1 = clp.minblur(2,2).removegrain(11,-1)
b1D = mt_makediff(clp,b1)
w1 = clp.aWarpSharp2(depth=warpdepth,blur=2,chroma=1)
w1b1 = w1.minblur(2,1).removegrain(11,-1)
w1b1D = mt_makediff(w1,w1b1)
DD = b1D.repair(w1b1D,13,-1)
DD2 = mt_makediff(b1D,DD)
clp.mt_makediff(DD2,U=2,V=2)
}

function YAHRmask(clip c, int "expand", int "warpdepth")
{
c
expand=default(expand,5)
warpdepth=default(warpdepth,32)
vEdge=mt_lutxy(mt_expand.mt_expand,"x y - abs 8 - 7 <<")
mt_merge(yahr2(warpdepth),\
vEdge.binomialblur(expand*2,u=1,v=1).mt_lut("x 4 <<").mt_logic(vEdge.removegrain(12,-1).mt_invert,"min"),\
u=2,v=2)
}



I tried to contact him again to ask for help, but had no answer.

Can you help me telling wich software I need or how to apply this filterings?
 
     Top
Abrazo
Posted: Jan 9 2015, 10:58 AM


Advanced Member


Group: Members
Posts: 775
Member No.: 28995
Joined: 5-November 10



Maybe it should be better to tell us what you are trying to do.

Remove noise, deshake, de-interlace, ...

There are a lot of filters available to use in combination with VirtualDub.
 
     Top
-vdub-
Posted: Jan 10 2015, 06:39 AM


Advanced Member


Group: Members
Posts: 613
Member No.: 27087
Joined: 24-February 10



An AviSynth script needs to have name extension .avs so that it can be loaded into Virtualdub. You will also need AviSynth installed the same that this script uses most probably the latest AviSynth version

Next will need to get all the external plugins that this script requires. When have them unpacked them into the AviSynth folder or sub folder (if or as required). Or you could go here http://avisynth.nl/index.php/Main_Page for AviSynth and all the external plugins the script needs. Easier would be to ask your friend for the filters that this script needs, even a list of which external filters would help you get this script working faster

I don't know of any web service where you could upload a script for it to automatically work out from the script which AviSynth version you would need. That would also provide a package bundle of all the external filters for the script so it can work

Maybe there are software out there that have all the latest AviSynth external filters so you can load this script to. Whether used to process your dvd or to gain info for which external filters you need so can install AviSynth to your system with those filters then able to process with Virtualdub
 
    Top
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:
2 replies since Jan 8 2015, 07:45 PM Track this topic | Email this topic | Print this topic

<< Back to VirtualDub Filters and Filter Development