Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 31 to 49 of 49
Thread
-
Oops, sorry. I was busy and forgot about this. Here's what I came up with.
Code:LWLibavVideoSource("teste.mkv", cache=false, prefer_hw=2) Y = GreyScale() U = UtoY() V = VtoY() # if you want to see the channels enable the next line #return(StackHorizontal(Y.Subtitle("Y"), StackVertical(U.Subtitle("U"), V.Subtitle("V")))) U = U.TurnRight() U = U.defreq(fx=7.5, fy=0.0, dx=3.0, dy=2.0, info=false, show=0) U = U.defreq(fx=15.0, fy=0.0, dx=3.0, dy=2.0, info=false, show=0) U = U.defreq(fx=22.5, fy=0.0, dx=3.0, dy=2.0, info=false, show=0) U = U.defreq(fx=30.0, fy=0.0, dx=3.0, dy=2.0, info=false, show=0) U = U.TurnLeft() # spacial only filtering on vertical axis to reduce remaining horizontal stripes #Y = Y.TNLMeans(Ax=0, Ay=20, h=8, rm=1) # if you want to filter Y too U = U.TNLMeans(Ax=0, Ay=10, h=6, rm=1) V = V.TNLMeans(Ax=0, Ay=6, h=6, rm=1) YtoUV(U, V, Y)
-
-
[Attachment 58326 - Click to enlarge]
In the case of these risks that appear throughout the video. Give to remove them? Is there a code to take? -
I see you started a new thread about this. I replied there. https://forum.videohelp.com/threads/401428-script-error-Help#post2616342
You can probably just blur them away. Need a video sample... -
At first I though you meant all those very thin vertical and horizontal lines in the sample image. But I see now those are a result of your camera photographing the screen. I think what you really mean the comets? Those two short black streaks in the image. You can get rid of most of those with RemoveDirt():
Code:LWLibavVideoSource("1978x29a.mkv") RemoveDirtMC(limit=10)
[Attachment 58335 - Click to enlarge]
Using a higher limit will remove more of them (but possibly mess up other things occasionally), a lower limit will remove less. -
Yes.The comets.
[Attachment 58336 - Click to enlarge] error
I downloaded RemoveDirt-0.9.3
[Attachment 58337 - Click to enlarge] which one should I use and where to put it ? -
RemoveDirtMC is a third party filter. You will need to download it and install any other third party filters it requires (that you don't already have). There are several variations around. The one I used comes from this thread:
https://forum.videohelp.com/threads/382527-Need-help-setting-up-avisynth-pls!#post2477423
Near the end of the big script there you'll see RemoveDirt() and RemoveDirtMC(). You can copy/paste from there into your script. I see they use RemoveGrain, fft3dfilter, and mvtools... -
Last edited by kelvin; 9th Apr 2021 at 14:31.
-
-
Generally, use whatever source filter that works. For VOB and MPG file I use DgIndex/MPEG2Source(). For MPEG 2 video in MKV I usually demux the video as an M2V elementary stream, then use DgIndex/Mpeg2Source(). That works best for MPEG2 with mixed hard/soft pulldown (and gives you access to its deringing and deblocking filters). For AVI files I use AviSource() if I have the video codec. LSMASH (LWlibavVideoSource(), LSMASHVideoSource(), and their audio counterparts) is a good general purpose source filter. Occasionally I'll use ffVideoSource() if LSMASH doesn't work right.
-
Let's see if I understand.
First use of input filter.
Then the filter I want.
So far I understood.
For me to get the script on the website, AviSynth how do I do it?
For example
I want to get the logo out of a movie.
http://avisynth.nl/index.php/External_filters#Logo_Removal
I go to the site and I have several options, but where do I go to get the code for my script and where is it?
[Attachment 58422 - Click to enlarge]
Is this where the code that I use in the script is located? -
[Attachment 58424 - Click to enlarge]
function RemoveDirt(clip input, bool "_grey", int "repmode")
{
_grey=default(_grey, false)
repmode=default(repmode, 16)
clmode=17
clensed=Clense(input, grey=_grey, cache=4)
sbegin = ForwardClense(input, grey=_grey, cache=-1)
send = BackwardClense(input, grey=_grey, cache=-1)
alt=Repair(SCSelect(input, sbegin, send, clensed, debug=true), input, mode=repmode, modeU = _grey ? -1 : repmode )
restore=Repair(clensed, input, mode=repmode, modeU = _grey ? -1 : repmode)
corrected=RestoreMotionBlocks(clensed, restore, neighbour=input, alternative=alt, gmthreshold=70, dist=1, dmode=2, debug=false, noise=10, noisy=12, grey=_grey)
return RemoveGrain(corrected, mode=clmode, modeU = _grey ? -1 : clmode )
If I'm going to use the demovedirt, is that the scrit I use?
Where do I put the source filter?
For example if it were "Teste.mkv"
#would that be correct?
LWLibavVideoSource("teste.mkv")
function RemoveDirt(clip input, bool "_grey", int "repmode")
{
_grey=default(_grey, false)
repmode=default(repmode, 16)
clmode=17
clensed=Clense(input, grey=_grey, cache=4)
sbegin = ForwardClense(input, grey=_grey, cache=-1)
send = BackwardClense(input, grey=_grey, cache=-1)
alt=Repair(SCSelect(input, sbegin, send, clensed, debug=true), input, mode=repmode, modeU = _grey ? -1 : repmode )
restore=Repair(clensed, input, mode=repmode, modeU = _grey ? -1 : repmode)
corrected=RestoreMotionBlocks(clensed, restore, neighbour=input, alternative=alt, gmthreshold=70, dist=1, dmode=2, debug=false, noise=10, noisy=12, grey=_grey)
return RemoveGrain(corrected, mode=clmode, modeU = _grey ? -1 : clmode ) -
Using something like:
Code:function Myfunction(clip c...) { filters... }
Code:function MyFunction(clip c...) { filters... } LWLibavVideoSource("input.mkv") MyFunction(...)
Code:# create a function called RemoverDirt function RemoveDirt(clip input, bool "_grey", int "repmode") { _grey=default(_grey, false) repmode=default(repmode, 16) clmode=17 clensed=Clense(input, grey=_grey, cache=4) sbegin = ForwardClense(input, grey=_grey, cache=-1) send = BackwardClense(input, grey=_grey, cache=-1) alt=Repair(SCSelect(input, sbegin, send, clensed, debug=true), input, mode=repmode, modeU = _grey ? -1 : repmode ) restore=Repair(clensed, input, mode=repmode, modeU = _grey ? -1 : repmode) corrected=RestoreMotionBlocks(clensed, restore, neighbour=input, alternative=alt, gmthreshold=70, dist=1, dmode=2, debug=false, noise=10, noisy=12, grey=_grey) return RemoveGrain(corrected, mode=clmode, modeU = _grey ? -1 : clmode ) } # open your source and apply RemoveDirt: LWLibavVideoSource("teste.mkv") RemoveDirt()
Code:LWLibavVideoSource("teste.mkv") RemoveDirt()
Code:last = LWLibavVideoSource("teste.mkv") # create a video stream from test2.mkv, explicitly name it last last = RemoveDirt(last) # apply RemoveDirt to last, creating a new filtered stream called again called last
-
LWLibavVideoSource("teste2.mkv")
InpaintDelogo( mask="c:\test\mymask.bmp",
\ Automask=0, aMix=0, Loc="100,100,-100,-100",
\ Mode="Inpaint",
\ Analyze=1, FrB=0, FrW=0, FrS=0)
InpaintDelogo ()
I made this script but it is not working.
[Attachment 58428 - Click to enlarge] -
I'm not familiar with InpaintDelogo() but does c:\test\mymask.bmp exist? And the Loc="100,100,-100,-100" probably isn't right as that has something to do with the location of the logo.
-
Do you have a script to remove the logo?
[Attachment 58448 - Click to enlarge] -
I have AvsInpaint:
http://avisynth.nl/index.php/AvsInpaint
which can be simple to use:
Code:########################################################################## # # Fill a rectangular box with a specified color. # ########################################################################## function BoxFill(clip v, int x, int y, int w, int h, int color) { BlankClip(v, color=color) Crop(0, 0, w, h) Overlay(v, last, x, y) } ########################################################################## ImageSource("logo.png", start=0, end=23, fps=23.976) Crop(0,0,-1,-1) # need even frame dimensions ConvertToYV12() # and YV12 #mask = ImageSource("mask.bmp", start=0, end=23, fps=23.976).ConvertToYV12(matrix="pc.601") mask = Overlay(mt_binarize(130),mt_binarize(100).Invert(), mode="add").mt_expand().mt_expand().mt_expand().mt_expand().mt_expand().mt_expand().GreyScale() mask = mask.BoxFill(0,0, 500, mask.height, $000000) mask = mask.BoxFill(500, 80, mask.width-500, mask.height-80, $000000) mask = mask.ColorYUV(cont_y=50) InpaintLogo(mask=mask, radius=5.0)
[Attachment 58449 - Click to enlarge]
Similar Threads
-
AviSynth Problem
By jseo13579 in forum EditingReplies: 4Last Post: 17th Nov 2018, 09:26 -
AviSynth - hasaudio problem
By queensoft in forum Video ConversionReplies: 18Last Post: 2nd Mar 2018, 08:47 -
Avisynth for interlace problem
By lordsmurf in forum RestorationReplies: 5Last Post: 3rd Jan 2018, 08:08 -
Trim problem with AVISynth
By smike in forum EditingReplies: 5Last Post: 9th Aug 2016, 09:20 -
Avisynth ImageSource Problem
By SameSelf in forum Video ConversionReplies: 7Last Post: 3rd Jul 2016, 20:02