digitalFAQ.com Forum

digitalFAQ.com Forum (https://www.digitalfaq.com/forum/)
-   General Discussion (https://www.digitalfaq.com/forum/news/)
-   -   Coming Soon: lordsmurf's Avisynth processing guides! (https://www.digitalfaq.com/forum/news/5895-coming-lordsmurfs-avisynth.html)

lordsmurf 05-10-2014 02:34 PM

Coming Soon: lordsmurf's Avisynth processing guides!
 
From now on, I'll be handling the video guides here again. I've been inactive on this front for far too long -- even before my medical episode from 2012 that grounded me for 18+ months (too much work, not enough hobby).

Coming first are my Avisynth processing guides, which I'm working on now.

The primary thing being worked on now is what I called the "MultiScript". It contains the most commonly needed filtering tasks for restoring videotapes and restoring VCDs. This coincides with several personal project, so it'll be perfect. I'm going to consolidate years worth of script into a single script to help others.

And unlike most Avisynth users, who are purists, I only use Avisynth when needed. Some tasks are inferior done in Avisynth, and I'll be pointing those out as well. I don't use multiple programs because I like to -- I use multiple program because I HAVE to! Sometimes VirtualDub, Adobe Premiere Pro and even TMPGEnc Plus 2.5 (shocking, I know!) are better choices -- color corrections, especially.

I'm nowhere near done EDIT -- Now much farther along. :)

If you want to take a quick peak, here's where I'm at so far:

Code:

### Avisynth MultiScript from lordsmurf @ digitalFAQ.com - see site for usage guides

### Load a file
# SetMemoryMax(512) # multithreaded Avisynth only - before source loaded p1
# SetMTMode(3) # multithreaded Avisynth only - before source loaded p2
# AVISource("c:\.avi")
# ffvideosource("c:\.m2v")
# DirectShowSource("c:\.wmv")
# ImageSource("c:\.jpg")
# SetMTMode(2)  # multithreaded Avisynth only - after source loaded

### / Load ----------------------------------------------------------------------------------------

ConvertToYUY2 # script below this line requires YUY2
# ConvertToYUY2(interlaced=true) # alternative that specifies interlacing

### Remove chroma errors
# Cnr2("xoo",4,2,64) # remove chroma banding noise, wide UV setting
# ChromaShift(C=2, L=-8) # align chroma over luma

### YUY2 color corrections
# ColorYUV(autowhite=true) # auto white balance

### Remove VHS magnetic dropouts (bad heads, "comets")
# DePulse(h=100, l=0, d=15, debug=false) # white -min
# DePulse(h=100, l=0, d=10, debug=false) # white
# DePulse(h=70, l=0, d=15, debug=false) # white -max
# DePulse(h=0, l=255, d=5, debug=false) # black

### / YUY2 ----------------------------------------------------------------------------------------

ConvertToYV12 # script below this line requires YV12

### YV12 color corrections
# MergeChroma(aWarpSharp(depth=10), aWarpSharp(depth=20)) # better white balance than ColorYUV(autowhite), use with overlay line below
# Overlay(last, ColorYUV(off_y=-8, off_u=9, off_v=-2), 0, 0, GreyScale(last).ColorYUV(cont_y=30)) # use with mergechroma line above

### Framerates
# AssumeFPS(25) # change NTSC to PAL

### VHS stabilizer
# StabMod() # lordsmurf PRE-deinterlace VHS jitter stab() alternative

### Deinterlacers
# ---- method 1 ----
# AssumeTFF() # optional, BFF for DV source
# QTGMC(Preset="Slower", SourceMatch=3, Lossless=2, MatchEnhance=0.75, TR2=1, Sharpness=0.1) # best but only 2fps!
# SelectEven()
# SelectOdd() # alternative
# ---- method 2 ----
# AssumeTFF() # optional, BFF for DV source
# QTGMC(Preset="Slow") # best deinterlacer - balances speed + quality
# SelectEven() #
# SelectOdd() # alternative
# ---- method 3 ----
# yadifmod(order=1, mode=0, edeint=NNEDI2(field=1)) # faster yadif deinterlace
# ---- method 4 ----
# SeparateFields # basic drop-field deinterlace, useful for some restorations
# SelectOdd 
# SelectEven # alternative

### Stabilizers
# ---- method 1 ----
# Stab()
# ---- method 2 ----
# StabMod() # lordsmurf POST-deinterlace VHS jitter stab() alternative
# StabMod() # stackable for bad VHS!
# ---- method 3 ----
# mdata = DePanEstimate(dxmax=0) # stab() alternative
# DePanStabilize(data=mdata, cutoff=0.5, damping=0.5, mirror=15, blur=30, method=1) # must use with mdata

### Antialiasing + compensation for deinterlace
# santiag(strh=2,strv=2) # antialiasing
# santiag(strh=4,strv=4) # antialiasing alternate for toons
# AAA(chroma=true) # antialiasing for toons - use with santiag
# AwarpSharp(depth=10) 
# Toon(strength=1.0)

### Common NR
# Deblock() # remove macroblocks
# Deen() # remove edge noise

### Semi-common NR
# DeGrainMedian(limitY=15,limitUV=7,mode=0, norow=true)
# TTempSmooth(maxr=4, strength=4, lthresh=5, cthresh=25, lmdiff=10, cmdiff=15)
# TTempSmooth(maxr=6, strength=4, lthresh=20, cthresh=25, lmdiff=10, cmdiff=15) # jagabo harsh NR
# TTempSmooth(maxr=5, strength=4, lthresh=16, cthresh=4) # further remove anime/toon ghosting post-TMPGEnc

### Less common NR
# RemoveGrain(mode=2, modeU=2, modeV=2)
# DFTTest()
# LSFMod(strength=50)
# FFT3DFilter(sigma=4, bt=3, plane=3)
# SRestore(FRate=29.97) # remove frame blending
# chubbyrain2(th=1, radius=15) # remove moire rainbows
# MosquitoNR(strength=16, restore=64, radius=2) # remove MPEG compression noise from toons

### Sharpeners
# Sharpen(0.5)

### YV12 Color correction
# ColorYUV(levels="PC->TV") # undo overly contrasted values
# ColorYUV(off_y=6, gain_y=-12) # lighten gamma
# ColorYUV(cont_u=-60, cont_v=-160) # increase saturation
# Levels(0,1.000,250,2,255,true)

### / YV12 ----------------------------------------------------------------------------------------

### Final resizers for destination format
# spline36resize(640,480) # resize to 4:3 video
# spline36resize(720,480) # resize to 4:3 DVD
# spline36resize(352,480) # resize to 4:3 Half D1 DVD

### Typical VHS overscan crop
# Crop(8,8,-22,-10) # use both lines
# AddBorders(15, 9, 15, 9) # use both lines

### Less common crop/pad with final resize from non-VHS (VCD,etc)
# spline36resize(640,480)
# Crop(4,4,632,472) # remove 4 overscan pixels
### Crop(16,16,-34,-16)
# spline36resize(720,480)
# AddBorders(16, 12, 16, 12) # add 4x3 overscan borders to cropped VCD
# spline36resize(720,480)

ConvertToYUY2 # assumes VirtualDub or MPEG encoder is next in video workflow chain
# SetMTMode(1) # multithreaded Avisynth only - end of script p1
# GetMTMode(false) > 0 ? distributor() : last # multithreaded Avisynth only - end of script p2

### /end MultiScript

____________

I'll be explaining what everything means, in a series of guides. Feel free to play with it now. And if you have questions, I'll answer them if easy.

Note: Everything is commented out. Uncomment what's needed.

I know a lot of people here are waiting for my help with various issues, and I'm getting to them as quickly as I can. Other site staff are busy on other things right now (hosting topics, new site features, in addition to our customers), so it's mostly just me for now. And I'm going to have some fun with the video topics this year!

lordsmurf 07-22-2014 11:28 PM

^ bump. Still working on this.

Suggestions are always welcome. If good, I'll surely incorporate them. :congrats:

sanCapture 08-10-2014 06:32 PM

Good to hear you are still working on this. I have a project to clean-up and encode about 10hrs of raw VHS video to x264 that I have been procrastinating on for months. My main dilemma is what to do about the interlacing. After comparing 12 different de-interlacing methods I came to the same conclusion that QTGMC provides a good balanced better result.

You might add a ConvertToYV12(interlaced=true) alternate line below the ConvertToYV12 line as well. I noticed a chroma/luma shift issue in my de interlaced video while comparing methods. I think QTGMC also supports YUY2 as well (with mt_masktools v25) so that color conversion might not be needed if just de interlacing.

Are you going to provide links to non built in filters? It took a bit to find a copy of the DePulse plugin.

lordsmurf 08-10-2014 07:03 PM

It will be a download pack attached to yet-to-be-made post. No hunting required! Just following the instructions. :)

Right now, I'm adding some, changing some around. I may go back and edit the above post, to reflect my current script.

I'll look into the QTGMC colorspace -- thanks for the tip! :congrats:

-- merged --

Script updated to most recent version. About 75% done now. :)

jriker1 12-08-2014 10:40 AM

I was playing with some of the options in your script lordsmurf and was wondering if I could get a copy of your StabMod() function/dll?

Also with your:

Code:

MergeChroma(aWarpSharp(depth=10), aWarpSharp(depth=20)) # better white balance than ColorYUV(autowhite), use with overlay line below
Overlay(last, ColorYUV(off_y=-8, off_u=9, off_v=-2), 0, 0, GreyScale(last).ColorYUV(cont_y=30)) # use with mergechroma line above

tags. Is it normal not to notice much or any difference when enabling these? Enabling ColorYUV(autowhite=true), earlier in the script instead, makes a drastic change. Not sure it's good though.

Thanks.

JR

Tafflad 04-18-2016 05:24 AM

As per comment in other thread ... please include CCD (Camcorder Color Denoise) in your multi-script.

Be interested if you will have any additions on Noise Reduction ... using MDegrain2 (or 3)
Look forward to the next update.

lordsmurf 04-18-2016 10:22 AM

Quote:

Originally Posted by Tafflad (Post 43520)
As per comment in other thread ... please include CCD (Camcorder Color Denoise) in your multi-script.

CCD (Camcorder Color Denoise) is a VirtualDub filter. Same for CNR (Chroma Noise Reduction).

Only CNR2 is Avisynth. And I don't often care for it, being that it's inferior to the others.

That other thread: http://www.digitalfaq.com/forum/news...on-chroma.html

pumapuma 04-19-2016 01:23 PM

Thanks again everyone for your contribution to this amazing script. Is it now mostly complete or finished? Also, I have got almost everything working except the Stabmod(). Or should I be using Stab() instead?

Thanks!

lordsmurf 04-19-2016 01:36 PM

1 Attachment(s)
Quote:

Originally Posted by jriker1 (Post 35465)
I was playing with some of the options in your script lordsmurf and was wondering if I could get a copy of your StabMod() function/dll?

Quote:

Originally Posted by pumapuma (Post 43535)
except the Stabmod()

Here you go. Attached. :congrats:

Quote:

Originally Posted by jriker1 (Post 35465)
Is it normal not to notice much or any difference when enabling these? Enabling ColorYUV(autowhite=true), earlier in the script instead, makes a drastic change. Not sure it's good though.

It's source dependent. While this line often works, sometimes it does not. If the footage is muddy or lacking good color, it's not going to work well, or at all. This line was created while trying to repair colors on cartoons. It's been useful on live-action as well, but it has to also have decent saturation.

Quote:

Originally Posted by pumapuma (Post 43535)
Or should I be using Stab() instead?

stab() is too erratic for VHS/tape sources. It's why I made the mod. It's more stable for tapes.

latreche34 04-19-2016 03:58 PM

Although I know the basic commands of the MS-DOS, I have no clue on how to start with Avisynth it will be nice if there is a step by step guide for dummies.

sanlyn 04-19-2016 06:07 PM

That'[s good. If you've typed out some of those goofy DOS command, Avisynth will make a little more sense.

Online help in html format is installed with Avisynth. Here's a link to the Getting Started" page, which is the same as the Help page: http://avisynth.nl/index.php/Getting_started. One note about the tutorial, some versions of this page say you can execute a script in Windows Media Player. Forget it. Use Avisynth.

latreche34 04-20-2016 02:21 AM

Guess what the first step where it says version() I have no clue what he is talking about, create a test file with what program?

Ok I read that thing again, So create a text file and name test and put version() in it and change the extension from .txt to .avs and open the text file with VirtualDub ??? I got an error message when opening the script test.avs file, Windows media player plyed the file as expected.
Ok reading more I figure out how to use avisynth with a video file AVISource("C:\Users\PCname\Desktop\test.avi")
But I was able to use it with windows media player only, I need to figure out how to use it with VirtualDub.

lordsmurf 04-20-2016 03:28 AM

Making Avisynth easy is my goal. But it takes time. In recent years, mostly because of my medical issues, time is something I lack. But I do work on this as much as I can.

Perhaps I'll stick up a brief mini-guide, which I can expand on later. Hmm... :hmm:

Tafflad 04-20-2016 07:10 AM

My mistake thought it was for AviSynth

Just on an understanding Q ....... AVIsynth 'drives' Virtual Dub, i.e the avsi file is loaded or dropped onto VD and it executes.

Can AviSynth therefore not tell VD to use the CCD filter ? ........... and pass it parameters to use ?
Or can't things operate that way.

sanlyn 04-20-2016 07:17 AM

Quote:

Originally Posted by latreche34 (Post 43547)
Guess what the first step where it says version() I have no clue what he is talking about, create a test file with what program?

Ok I read that thing again, So create a text file and name test and put version() in it and change the extension from .txt to .avs and open the text file with VirtualDub ??? I got an error message when opening the script test.avs file, Windows media player plyed the file as expected.
Ok reading more I figure out how to use avisynth with a video file AVISource("C:\Users\PCname\Desktop\test.avi")
But I was able to use it with windows media player only, I need to figure out how to use it with VirtualDub.

To open an .avs file with VirtualDub, use "File..." -> "Open video file...", and navigate to the .avs file. VirtualDub doesn't know Avisynth exists -- it just thinks Avisynth's output is another video (which it is, actually). Don't use "run script" -- it's for VirtualDub scripts only, which are not .avs files.

To create or edit .avs files most people use Notepad. When you click "Save" or "Save As" in Notepad, go down to the "Files of type..." window and choose "All files", change the file ending to .avs, and save. OF course, after the script is created and already exists as an .avs, just click "Save" and the .avs file ending will still be there.

Another way to open an .avs in VirtualDub is to go into File Manager (or whatever the Windows Explorer folder browser is called these days, or open with My Computer"), select the .avs file, right click, and in the popup menu choose "Open with..." . When you see the list of programs available for opening files, look for VirtualDub in the list. If it isn't there, go to "Choose Program" and browse for Virtualdub.exe in the VirtualDub program folder, then left-click to open in VirtualDub. After you do this once, VirtualDub will appear in that list of available programs.

latreche34 04-20-2016 11:55 AM

I'm still getting an error message when trying to open the .avs file with virtualdub, maybe because avisynth is 32bit and virtualdub is 64bit.

sanlyn 04-20-2016 12:45 PM

Yep. That's the problem. :eek:

Can't mix 32 and 64. Use 32-bit for Avisynth and Virtualdub. There are very few 64-bit plugins on the planet, and no one is in a hurry to re-develop hundreds of well known 32-bit filters. And here are hundreds of 'em, literally. For Avisynth alone, here is one page: http://avisynth.nl/index.php/External_filters. There are many more listings. VirtualDub, too.

latreche34 04-20-2016 02:56 PM

Ok all good now after installing VirtDub 32bit, Where do I get QTGMC and what is the script to remove chroma shifting as well as right side red or green vertical bar on the edge for PAL videos?
One more question, When adding filters to avisynth, should I copy the whole folder of the filter to the plugins folder of avisynth or dump the files of the filters in the plugins folder?

sanlyn 04-20-2016 03:53 PM

Every video requires specific filters and settings. So for your last question it would be better to start a new thread and show us a piece of the video.

For Avisynth and Virtualdub filters, create a folder to contain the download. Downloads are usually zip'd or rar, etc., and decompressing them into your plugins folder will fill the folder with unwanted files, many of which are different versions with the same name, many of which are in zip'd subfolders, and many of which are documentation. Unzip filters in their own folders, then copy the correct file or files into your plugins.

On my PC's I have a big folder for Avisynth plugins and another for VirtualDub's. Inside those folders are subfolders for each filter. The subfolders are also handy for saving articles and examples about using the filters.

QTGMC 3-32 and support files are here: http://forum.doom9.org/showthread.php?t=156028. Use 32-bit only. Avoid the newer 3-33.avsi, it's buggy.

lordsmurf 04-21-2016 02:01 AM

1 Attachment(s)
I didn't want to do this yet, as it's not tested, and my install guide isn't done.

Attached are (most of) my current plugins from "C:\Program Files (x86)\AviSynth\plugins" on my main system. You need to install Avisynth 2.6 official, and then unzip my plugins into that folder. Yes, overwrite anything if asked.

In theory, anything I say to do will guaranteed work, including anything in my MultiScript. :congrats:

Attachment fixed. -LS
Older stats: 48 downloads

latreche34 04-21-2016 02:11 AM

Quote:

Originally Posted by lordsmurf (Post 43574)
I didn't want to do this yet, as it's not tested, and my install guide isn't done.

Attached are (most of) my current plugins from "C:\Program Files (x86)\AviSynth\plugins" on my main system. You need to install Avisynth 2.6 official, and then unzip my plugins into that folder. Yes, overwrite anything if asked.

In theory, anything I say to do will guaranteed work, including anything in my MultiScript. :congrats:

Thanks for sharing, Pretty handy. And thanks Sanlyn for the help. I will start a separate thread if any problems arise.

bilbofett 04-22-2016 09:22 PM

Thanks for the share Lordsmurf!
It's very generous of you!
P.S. Didn't like my Big Mac joke? :)
brothers Msgohan and especially sanlyn have been doing the heavy lifting for me, very helpful! :)

lordsmurf 04-22-2016 10:09 PM

I don't recall a Big Mac joke. :question:

bilbofett 04-22-2016 10:46 PM

Quote:

Originally Posted by lordsmurf (Post 43602)
I don't recall a Big Mac joke. :question:

Check post #38 in this thread here: http://www.digitalfaq.com/forum/vide...capture-2.html

lordsmurf 04-23-2016 01:31 AM

Quote:

Originally Posted by bilbofett (Post 43606)
Check post #38 in this thread here:

Replied: http://www.digitalfaq.com/forum/vide...html#post43629

billct97 03-06-2018 09:15 PM

Quote:

Originally Posted by lordsmurf (Post 31825)
From now on, I'll be handling the video guides here again. I've been inactive on this front for far too long -- even before my medical episode from 2012 that grounded me for 18+ months (too much work, not enough hobby).

Coming first are my Avisynth processing guides, which I'm working on now.

The primary thing being worked on now is what I called the "MultiScript". It contains the most commonly needed filtering tasks for restoring videotapes and restoring VCDs. This coincides with several personal project, so it'll be perfect. I'm going to consolidate years worth of script into a single script to help others.

And unlike most Avisynth users, who are purists, I only use Avisynth when needed. Some tasks are inferior done in Avisynth, and I'll be pointing those out as well. I don't use multiple programs because I like to -- I use multiple program because I HAVE to! Sometimes VirtualDub, Adobe Premiere Pro and even TMPGEnc Plus 2.5 (shocking, I know!) are better choices -- color corrections, especially.

I'm nowhere near done EDIT -- Now much farther along. :)

If you want to take a quick peak, here's where I'm at so far:

Code:

### Avisynth MultiScript from lordsmurf @ digitalFAQ.com - see site for usage guides

### Load a file
# SetMemoryMax(512) # multithreaded Avisynth only - before source loaded p1
# SetMTMode(3) # multithreaded Avisynth only - before source loaded p2
# AVISource("c:\.avi")
# ffvideosource("c:\.m2v")
# DirectShowSource("c:\.wmv")
# ImageSource("c:\.jpg")
# SetMTMode(2)  # multithreaded Avisynth only - after source loaded

### / Load ----------------------------------------------------------------------------------------

ConvertToYUY2 # script below this line requires YUY2
# ConvertToYUY2(interlaced=true) # alternative that specifies interlacing

### Remove chroma errors
# Cnr2("xoo",4,2,64) # remove chroma banding noise, wide UV setting
# ChromaShift(C=2, L=-8) # align chroma over luma

### YUY2 color corrections
# ColorYUV(autowhite=true) # auto white balance

### Remove VHS magnetic dropouts (bad heads, "comets")
# DePulse(h=100, l=0, d=15, debug=false) # white -min
# DePulse(h=100, l=0, d=10, debug=false) # white
# DePulse(h=70, l=0, d=15, debug=false) # white -max
# DePulse(h=0, l=255, d=5, debug=false) # black

### / YUY2 ----------------------------------------------------------------------------------------

ConvertToYV12 # script below this line requires YV12

### YV12 color corrections
# MergeChroma(aWarpSharp(depth=10), aWarpSharp(depth=20)) # better white balance than ColorYUV(autowhite), use with overlay line below
# Overlay(last, ColorYUV(off_y=-8, off_u=9, off_v=-2), 0, 0, GreyScale(last).ColorYUV(cont_y=30)) # use with mergechroma line above

### Framerates
# AssumeFPS(25) # change NTSC to PAL

### VHS stabilizer
# StabMod() # lordsmurf PRE-deinterlace VHS jitter stab() alternative

### Deinterlacers
# ---- method 1 ----
# AssumeTFF() # optional, BFF for DV source
# QTGMC(Preset="Slower", SourceMatch=3, Lossless=2, MatchEnhance=0.75, TR2=1, Sharpness=0.1) # best but only 2fps!
# SelectEven()
# SelectOdd() # alternative
# ---- method 2 ----
# AssumeTFF() # optional, BFF for DV source
# QTGMC(Preset="Slow") # best deinterlacer - balances speed + quality
# SelectEven() #
# SelectOdd() # alternative
# ---- method 3 ----
# yadifmod(order=1, mode=0, edeint=NNEDI2(field=1)) # faster yadif deinterlace
# ---- method 4 ----
# SeparateFields # basic drop-field deinterlace, useful for some restorations
# SelectOdd 
# SelectEven # alternative

### Stabilizers
# ---- method 1 ----
# Stab()
# ---- method 2 ----
# StabMod() # lordsmurf POST-deinterlace VHS jitter stab() alternative
# StabMod() # stackable for bad VHS!
# ---- method 3 ----
# mdata = DePanEstimate(dxmax=0) # stab() alternative
# DePanStabilize(data=mdata, cutoff=0.5, damping=0.5, mirror=15, blur=30, method=1) # must use with mdata

### Antialiasing + compensation for deinterlace
# santiag(strh=2,strv=2) # antialiasing
# santiag(strh=4,strv=4) # antialiasing alternate for toons
# AAA(chroma=true) # antialiasing for toons - use with santiag
# AwarpSharp(depth=10) 
# Toon(strength=1.0)

### Common NR
# Deblock() # remove macroblocks
# Deen() # remove edge noise

### Semi-common NR
# DeGrainMedian(limitY=15,limitUV=7,mode=0, norow=true)
# TTempSmooth(maxr=4, strength=4, lthresh=5, cthresh=25, lmdiff=10, cmdiff=15)
# TTempSmooth(maxr=6, strength=4, lthresh=20, cthresh=25, lmdiff=10, cmdiff=15) # jagabo harsh NR
# TTempSmooth(maxr=5, strength=4, lthresh=16, cthresh=4) # further remove anime/toon ghosting post-TMPGEnc

### Less common NR
# RemoveGrain(mode=2, modeU=2, modeV=2)
# DFTTest()
# LSFMod(strength=50)
# FFT3DFilter(sigma=4, bt=3, plane=3)
# SRestore(FRate=29.97) # remove frame blending
# chubbyrain2(th=1, radius=15) # remove moire rainbows
# MosquitoNR(strength=16, restore=64, radius=2) # remove MPEG compression noise from toons

### Sharpeners
# Sharpen(0.5)

### YV12 Color correction
# ColorYUV(levels="PC->TV") # undo overly contrasted values
# ColorYUV(off_y=6, gain_y=-12) # lighten gamma
# ColorYUV(cont_u=-60, cont_v=-160) # increase saturation
# Levels(0,1.000,250,2,255,true)

### / YV12 ----------------------------------------------------------------------------------------

### Final resizers for destination format
# spline36resize(640,480) # resize to 4:3 video
# spline36resize(720,480) # resize to 4:3 DVD
# spline36resize(352,480) # resize to 4:3 Half D1 DVD

### Typical VHS overscan crop
# Crop(8,8,-22,-10) # use both lines
# AddBorders(15, 9, 15, 9) # use both lines

### Less common crop/pad with final resize from non-VHS (VCD,etc)
# spline36resize(640,480)
# Crop(4,4,632,472) # remove 4 overscan pixels
### Crop(16,16,-34,-16)
# spline36resize(720,480)
# AddBorders(16, 12, 16, 12) # add 4x3 overscan borders to cropped VCD
# spline36resize(720,480)

ConvertToYUY2 # assumes VirtualDub or MPEG encoder is next in video workflow chain
# SetMTMode(1) # multithreaded Avisynth only - end of script p1
# GetMTMode(false) > 0 ? distributor() : last # multithreaded Avisynth only - end of script p2

### /end MultiScript

____________

I'll be explaining what everything means, in a series of guides. Feel free to play with it now. And if you have questions, I'll answer them if easy.

Note: Everything is commented out. Uncomment what's needed.

I know a lot of people here are waiting for my help with various issues, and I'm getting to them as quickly as I can. Other site staff are busy on other things right now (hosting topics, new site features, in addition to our customers), so it's mostly just me for now. And I'm going to have some fun with the video topics this year!

LS, is this still your day to day working script or have there been updates you would be willing to share?

lordsmurf 03-08-2018 11:26 PM

My day-to-day script got complicated when I threw Avisynth+ x64 into the mix.

There are updates, quite a few actually, but I'm not willing to share those just yet. All it'd do is confuse you, and create more questions. Long-term, I'd spend more time answering those questions than just spending it working on the scripts (and FAQ/guide, glossary entries, etc). Plus I think laying it out in a guide would be better, as it'll be sequential. That matters more than most people realize.

I'll do that in April/May.

RockandRoller70 03-27-2018 12:35 PM

Whenever I try to use Stab() or StabMod() I get the following error:

"there is no function named 'Repair'"

I am using the plugins provided by lordsmurf and even added in repair.dll after doing some research but to no avail.

SetMTMode is also not being accepted.

Hmmm... wonder where I'm going wrong.

RockandRoller70 03-27-2018 04:05 PM

Nevermind, I think I have things working now. Love the great resources on this site!

MelnickStudios 04-17-2018 11:43 AM

Please if you can help me I'd appreciate it. To date I've been using Vdub 32 & avisynth MT 32 and am trying to update to 64-bit MT.

I'm trying to deinterlace using QTGMC, Virtualdub2 64-bit & Avisynth+ MT 64-bit.


I'm not sure what the issue is with my script or if it's my install - or both!

I just installed:
Virtualdub2 41585
Avisynth+ r2664


I put libfftw3f-3.dll & libfftw3f-3.lll renamed as FFTW3.dll in C:\Windows\System32


Plugins Directory:
C:\Program Files (x86)\AviSynth+\plugins64+

Plugins: (all latest updated versions)
AddGrainC.dll
AnimeIVTCmod_v2.20.avsi
colors_rgb.avsi
colors_rgb.txt
ConvertStacked.dll
DePan.dll
DePanEstimate.dll
dfttest.dll (this is from the avx2 folder)
DirectShow5ource.dll
EEDI2.dll
eedi3.dll
fft3dfilter.dll
lmageSeq.dll
KNLMeansCL.dll
masktools2.dll
mvtools2.dll
nnedi3.dll
PlanarTools.dll
QTGMC.avsi
RgTools.dll
Shibatch.dll
SMDegrain_v3.l.2.93s.avsi
TDeinterlace.dll
TimeStretch.dll
VDubFilter.dll
yadifmod2.dll
yadifmod2_avx2.dll


VirtualDub Error
Avisynth open failure:
System exception - Illegal Instruction
(C:/Program Files (x86)/Avisynth+/plugins64+/QTGMC.avsi, line 862)
(C:/Program Files (x86)/Avisynth+/plugins64+/QTGMC.avsi, line 620)
(D:\Video Transfers\File001.avs, line 6)

Script:

SetMemoryMax(1024)
SetFilterMTMode("DEFAULT_MT_MODE", 2)
AVISource("D:\Video Transfers\File001.avi")
ConvertToYV12()
AssumeTFF()
QTGMC(Preset="Slower", SourceMatch=3, Lossless=2, MatchEnhance=0.75, TR2=1, Sharpness=0.1)
ConvertToYUY2()
Prefetch(4)

Any suggestions to make this work would be greatly appreciated! Thanks!

hodgey 04-17-2018 11:56 AM

Quote:

System exception - Illegal Instruction
What processor do you have? It loos like one of the plugins is using instructions that your processor does not support (maybe AVX2?).
From the line in the QTGMC script it stops on (if it's the same version that I have at least), it looks like it could be caused by either yadifmod or removegrain.

I'm using avs+ 64-bit with qtgmc myself, so I know it's doable.

MelnickStudios 04-17-2018 12:01 PM

My processor is:
Intel Core i7-3930K @ 3.20 GHZ
The version of QTGMC is: 3.357

Is there a compatibility issue you know of?

Thanks for your help.

hodgey 04-17-2018 12:07 PM

Ah, yeah that is an older processor so it doesn't support AVX2 (which was introduced in the next generation of intel processors).
Youl will need the non-AVX2 versions of the libraries then. (i.e delete yadifmod_avx2.dll and don't use the avx2 version of libfftw3f-3.dll. (Also I don't think they need to be renamed either.)

MelnickStudios 04-17-2018 02:08 PM

I'm still getting the same error. Maybe it's my code?

Here's what I changed:
  • I switched dfttest.dll from the avx2 one to the avx one
  • I deleted yadifmod_avx2.dll

I'm not quite sure what to do about ensuring I am using the correct install procedure for FFTW3, I just followed these instructions from the QTGMC wiki page:

"Dfttest, FFT3DFilter and MVTools2 need the FFTW3 library (windows builds). On a 64-bit Windows OS, extract the 32-bit libfftw3f-3.dll. Make a copy of it and rename it as "FFTW3.dll". Place the files "libfftw3f-3.dll" and "FFTW3.dll" in the SysWow64 folder.

If you want to use the 64-bit libfftw3f-3.dll versions then extract the 64-bit libfftw3f-3.dll. Make a copy of it and rename it as "FFTW3.dll". Place the files "libfftw3f-3.dll" and "FFTW3.dll" in the System32 folder."

I used the 64 bit version of libfftw3f-3.dll and made the FFTW3.dll copy as well. Should I be using the 32 bit version? Which one is not avx2?

MelnickStudios 04-17-2018 02:35 PM

The Script I used works only in Ultra Fast mode.

hodgey 04-17-2018 03:45 PM

ah sorry I meant dfftest, not libfftw3f. That one should be fine.
If it works in ultra fast mode it's probably NNEEDI3 you have the wrong version of (as it's use is replaced with yadifmod in that preset). If you got the one linked on the avisynth wiki, there are several dlls in the download. You will want the one that's in the "Release_W7_AVX" folder (NOT AVX2). (The two other (non-AVX) versions will work as well but the AVX one will probably be the fastest one.)

MelnickStudios 04-17-2018 03:58 PM

You solved my issue! I was using the avx2 version of nnedi3 instead of avx. Thank you very much! It's fine now.

As a side point, am I correct that it's no longer necessary to convert yuy2 to yv12 before QTGMC and then back to yuy2 after?

I'm basically capturing uncompressed AVI and saving to avi as PicVideo MJPEG.

Here's my current code, how does it look:

SetMemoryMax(1024)
SetFilterMTMode("DEFAULT_MT_MODE", 2)
AVISource("D:\Video Transfers\File001.avi")
#ConvertToYV12()
AssumeTFF()
QTGMC(Preset="Very Slow", SourceMatch=3, Lossless=2, MatchEnhance=0.75, TR2=1, Sharpness=0.1)
#ConvertToYUY2()
Prefetch(6)

hodgey 04-17-2018 05:04 PM

Yeah it should work with yuy2.

Mejnour 07-20-2018 09:50 AM

Lordsmurf is right no satisfying Avisynth guide available so far.
Greatly waiting for his version:wink2:

bar72 10-17-2018 08:25 PM

Just spent around a week trying to get my head around avisynth before I capture anything. noticing that certain calls require certain versions of .dll or I get errors so your template and plugin pack are greatly appreciated, lordsmurf ;)


All times are GMT -5. The time now is 04:26 AM

Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.