<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://www.avisynth.nl/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=AlanHK</id>
	<title>Avisynth wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://www.avisynth.nl/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=AlanHK"/>
	<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php/Special:Contributions/AlanHK"/>
	<updated>2026-09-13T10:29:03Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Plugins&amp;diff=4963</id>
		<title>Plugins</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Plugins&amp;diff=4963"/>
		<updated>2014-11-20T03:07:30Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: /* Plugin autoload and name precedence v2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Commands for loading plugins ==&lt;br /&gt;
&lt;br /&gt;
With these functions you can add external functions to AviSynth.&lt;br /&gt;
&lt;br /&gt;
 LoadPlugin (&amp;quot;filename&amp;quot; [, ...])&lt;br /&gt;
&lt;br /&gt;
Loads one or more external avisynth plugins (DLLs).&lt;br /&gt;
&lt;br /&gt;
 LoadVirtualDubPlugin (&amp;quot;filename&amp;quot;, &amp;quot;filtername&amp;quot;, preroll)&lt;br /&gt;
&lt;br /&gt;
This loads a plugin written for [[VirtualDub]]. &amp;quot;filename&amp;quot; is the name of the .vdf file. After calling this function, the filter will be known as &amp;quot;filtername&amp;quot; in AviSynth. VirtualDub filters only supports [[RGB32]]. If the video happens to be in RGB24-format, then you must use [[ConvertToRGB32]] ([[ConvertToRGB]] won&#039;t suffice).&lt;br /&gt;
&lt;br /&gt;
Some filters output depends on previous frames; for those preroll should be set to at least the number of frames the filter needs to pre-process to fill its buffers and/or updates its internal variables.&lt;br /&gt;
&lt;br /&gt;
 LoadVFAPIPlugin (&amp;quot;filename&amp;quot;, &amp;quot;filtername&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
This allows you to use VFAPI plugins (TMPGEnc import plugins).&lt;br /&gt;
&lt;br /&gt;
 LoadCPlugin (&amp;quot;filename&amp;quot; [, ...])&lt;br /&gt;
 Load_Stdcall_Plugin (&amp;quot;filename&amp;quot; [, ...])&lt;br /&gt;
&lt;br /&gt;
Loads so called Avisynth C-plugins (DLLs).&lt;br /&gt;
Load_Stdcall_Plugin() is an alias for LoadCPlugin(). &lt;br /&gt;
C-plugins are created on pure C language and use special &amp;quot;AviSynth C API&amp;quot; (unlike ordinary Avisynth plugins which are created with MS C++). C-plugins must be loaded with LoadCPlugin() or Load_Stdcall_Plugin().&lt;br /&gt;
&lt;br /&gt;
Kevin provides a LoadCPlugin.dll that overloads the LoadCPlugin() verb to support plugins compiled using the C subroutine calling sequence, use Load_Stdcall_Plugin() to load stdcall calling sequence plugins when using Kevins version. Advice: keep these plugins outside your auto plugin loading directory to prevent crashes. ([http://forum.doom9.org/showthread.php?s=&amp;amp;threadid=58840 discussion]), ([http://kevin.atkinson.dhs.org/avisynth_c/ AVISynth C API (by kevina20723)]).&lt;br /&gt;
&lt;br /&gt;
== Plugin autoload and name precedence v2 ==&lt;br /&gt;
&lt;br /&gt;
It is possible to put all plugins and script files with [[User_defined_script_functions|user-defined functions]] or (global) [[Script_variables|variables]] in a directory from where all files with the extension .AVSI (v2.08, v2.5, the type was .AVS in v2.05-2.07) and .DLL are loaded at startup, unloaded and then loaded dynamically as the script needs them.&lt;br /&gt;
&lt;br /&gt;
.AVSI scripts in this directory should only contain function definitions and global variables, no main processing section (else strange errors may occur), it also is not recommended to put other files in that directory.&lt;br /&gt;
&lt;br /&gt;
The directory is stored in the registry (the registry key has changed for v2.5). You can use double-clicking a .REG-file with the following lines to set the path (of course inserting your actual path):&lt;br /&gt;
 &lt;br /&gt;
 REGEDIT4&lt;br /&gt;
 &lt;br /&gt;
 [HKEY_LOCAL_MACHINE\SOFTWARE\Avisynth]&lt;br /&gt;
 &amp;quot;plugindir2_5&amp;quot;=&amp;quot;c:\\program files\\avisynth 2.5\\plugins&amp;quot;&lt;br /&gt;
&lt;br /&gt;
The order in which function names take precedence is as follows:&lt;br /&gt;
&lt;br /&gt;
* user-defined function (always have the highest priority)&lt;br /&gt;
** plugin-function (higher priority than built-in, will override a built-in function)&lt;br /&gt;
*** built-in function&lt;br /&gt;
&lt;br /&gt;
Inside those groups the function loaded at last takes precedence, there is no error in a namespace conflict.&lt;br /&gt;
&lt;br /&gt;
== Plugin autoload and conflicting function names v2.55 ==&lt;br /&gt;
&lt;br /&gt;
Starting from v2.55 there is DLLName_function() support. The problem is that two plugins can have different functions which are named the same. To call the needed one, DLLName_function() support is added. It auto-generates the additional names both for auto-loaded plugins and for plugins loaded with LoadPlugin.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Some examples:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 # using fielddeinterlace from decomb510.dll&lt;br /&gt;
 AviSource(&amp;quot;D:\captures\jewel.avi&amp;quot;)&lt;br /&gt;
 decomb510_fielddeinterlace(blend=false)&lt;br /&gt;
&lt;br /&gt;
Suppose you have  the plugins mpeg2dec.dll and mpeg2dec3.dll in your auto plugin dir, and you want to load a d2v file with mpeg2dec.dll (which outputs YUY2):&lt;br /&gt;
&lt;br /&gt;
 # using mpeg2source from mpeg2dec.dll&lt;br /&gt;
 mpeg2dec_mpeg2source(&amp;quot;F:\From_hell\from_hell.d2v&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
or with mpeg2dec3.dll (which outputs YV12):&lt;br /&gt;
&lt;br /&gt;
 # using mpeg2source from mpeg2dec3.dll&lt;br /&gt;
 mpeg2dec3_mpeg2source(&amp;quot;F:\From_hell\from_hell.d2v&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Back to [[AviSynth Syntax]].&lt;br /&gt;
&lt;br /&gt;
[[Category:AviSynth_Syntax]]&lt;br /&gt;
[[Category:Scripting_Basics]]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=EditingFunctions&amp;diff=939</id>
		<title>EditingFunctions</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=EditingFunctions&amp;diff=939"/>
		<updated>2012-01-21T07:32:22Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: missing++&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here are some functions I made and added to my plugins directory because I was sick of typing them so much. Hope you find them useful.&lt;br /&gt;
&lt;br /&gt;
    # inserts the clip &#039;inclip&#039; into &#039;old&#039; at index &#039;frame&#039;&lt;br /&gt;
    function Insert (clip old, clip inclip, int frame)&lt;br /&gt;
    {&lt;br /&gt;
        return old.[[Trim]](0, frame - 1) + inclip + old.Trim(frame, 0)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    # as above, using aligned splices&lt;br /&gt;
    function AlignedInsert (clip old, clip inclip, int frame)&lt;br /&gt;
    {&lt;br /&gt;
        return old.Trim(0, frame - 1) ++ inclip ++ old.Trim(frame, 0)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    # replace &#039;numframes&#039; frames of &#039;old&#039; with &#039;inclip&#039;, starting at &#039;frame&#039;&lt;br /&gt;
    function Replace (clip old, clip inclip, int frame, int numframes)&lt;br /&gt;
    {&lt;br /&gt;
        numframes = ((numframes == 0) || (numframes &amp;gt; inclip.[[Clip_properties|framecount]])) ? inclip.framecount : numframes&lt;br /&gt;
        return old.Trim(0, frame - 1) + inclip.Trim(0, numframes) + old.Trim(frame + numframes, 0)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    # as above, using aligned splices&lt;br /&gt;
    function AlignedReplace (clip old, clip inclip, int frame, int numframes)&lt;br /&gt;
    {&lt;br /&gt;
        numframes = (numframes == 0 || numframes &amp;gt; inclip.framecount) ? inclip.framecount : numframes&lt;br /&gt;
        return old.Trim(0, frame - 1) ++ inclip.Trim(0, numframes) ++ old.Trim(frame + numframes, 0)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
[[Category:Shared functions]]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Subtitle&amp;diff=582</id>
		<title>Subtitle</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Subtitle&amp;diff=582"/>
		<updated>2011-09-07T06:56:12Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: multi-line is allowed&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:FuncDef|Subtitle(clip &#039;&#039;clip&#039;&#039;, string &#039;&#039;text&#039;&#039;, float &#039;&#039;x&#039;&#039;, float &#039;&#039;y&#039;&#039;, int &#039;&#039;first_frame&#039;&#039;, int &#039;&#039;last_frame&#039;&#039;, string &#039;&#039;font&#039;&#039;, int &#039;&#039;size&#039;&#039;, int &#039;&#039;text_color&#039;&#039;, int &#039;&#039;halo_color&#039;&#039;, int &#039;&#039;align&#039;&#039;, int &#039;&#039;spc&#039;&#039;, int &#039;&#039;lsp&#039;&#039;, float &#039;&#039;font_width&#039;&#039;, float &#039;&#039;font_angle&#039;&#039;, bool &#039;&#039;interlaced&#039;&#039;)|Subtitle(clip &#039;&#039;clip&#039;&#039;, string &#039;&#039;text&#039;&#039;)}}&lt;br /&gt;
&lt;br /&gt;
The Subtitle filter adds anti-aliased text to a range of frames. All parameters after &#039;&#039;text&#039;&#039; are optional and can be omitted or specified out of order using the &#039;&#039;name=value&#039;&#039; syntax.&lt;br /&gt;
&lt;br /&gt;
===Parameters===&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;text&#039;&#039; is the text which will be overlayed on the clip starting from frame &#039;&#039;first_frame&#039;&#039; and ending with frame &#039;&#039;last_frame&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;x&#039;&#039;,&#039;&#039;y&#039;&#039;) is the position of the text. The parameters &#039;&#039;x&#039;&#039; and &#039;&#039;y&#039;&#039; can be set to -1 to automatically calculate and use the horizontal or vertical center coordinate. Other negative values of &#039;&#039;x&#039;&#039; and &#039;&#039;y&#039;&#039; can be used to give subtitles partially off the screen. &#039;&#039;&#039;Caution:&#039;&#039;&#039; If your script uses Subtitle with [[Animate]] and negative &#039;&#039;x&#039;&#039; or &#039;&#039;y&#039;&#039; values, &#039;&#039;x&#039;&#039; or &#039;&#039;y&#039;&#039; might momentarily become -1, causing a glitch in the video. Starting from v2.60 they can be float.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;font&#039;&#039; is the font of the text (all installed fonts on the current machine are available, they are located in your &#039;windows\fonts&#039; folder).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;size&#039;&#039; is the height of the text in pixels, and is rounded to the nearest 0.125 pixel.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;text_color&#039;&#039; and &#039;&#039;halo_color&#039;&#039; should be given as hexadecimal $aarrggbb values, similar to HTML--except that they start with $ instead of # and the 4th octet specifies the alpha transparency. $00rrggbb is completely opaque, $FF000000 is fully transparent. You can disable the halo by selecting this color. See [[Colors]] for more information on specifying colors.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;align&#039;&#039; parameter allows you to set where the text is placed relative to the (x,y) location and is based on the numeric keypad as follows:&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;left&amp;gt; 7 &amp;lt;top&amp;gt;&lt;br /&gt;
| &amp;lt;nowiki&amp;gt;&amp;lt;center&amp;gt;&amp;lt;/nowiki&amp;gt; 8 &amp;lt;top&amp;gt;&lt;br /&gt;
| &amp;lt;right&amp;gt; 9 &amp;lt;top&amp;gt;&lt;br /&gt;
| top of text aligned to y-location for align=7,8,9&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;left&amp;gt; 4 &amp;lt;baseline&amp;gt;&lt;br /&gt;
| &amp;lt;nowiki&amp;gt;&amp;lt;center&amp;gt;&amp;lt;/nowiki&amp;gt; 5 &amp;lt;baseline&amp;gt;&lt;br /&gt;
| &amp;lt;right&amp;gt; 6 &amp;lt;baseline&amp;gt;&lt;br /&gt;
| baseline of text aligned to y-location for align=4,5,6&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;left&amp;gt; 1 &amp;lt;bottom&amp;gt;&lt;br /&gt;
| &amp;lt;nowiki&amp;gt;&amp;lt;center&amp;gt;&amp;lt;/nowiki&amp;gt; 2 &amp;lt;bottom&amp;gt;&lt;br /&gt;
| &amp;lt;right&amp;gt; 3 &amp;lt;bottom&amp;gt;&lt;br /&gt;
| bottom of text aligned to y-location for align=1,2,3&lt;br /&gt;
|-&lt;br /&gt;
| start at x for align=1,4,7&lt;br /&gt;
| center on x for align=2,5,8&lt;br /&gt;
| end at x for align=3,6,9&lt;br /&gt;
| &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Note: There is no Y-center alignment setting.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;spc&#039;&#039; parameter allows you to modify the character spacing (0=unchanged). The value can be positive or negative to widen or narrow the text. Per the Visual C++ documentation of the function SetTextCharacterExtra(), that performs this task, this value is in logical units and rounded to the nearest 0.125 pixel. This is helpful for trying to match typical fonts on the PC to fonts used in film and television credits which are usually wider for the same height or to just fit or fill in a space with a fixed per-character adjustment.&lt;br /&gt;
&lt;br /&gt;
Multi-line text using &amp;quot;\n&amp;quot; is added in v2.57 and it is used if the lsp (line spacing) parameter is set. It sets the additional line space between two lines in 0.125 pixel units. (In the unlikely event that you want to output the characters &amp;quot;\n&amp;quot; literally in a multi-line text, you can do this by using &amp;quot;\\n&amp;quot;.)&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;font_width&#039;&#039; parameter allows you to modify, in 0.125 units, the aspect ratio of character glyphs per the Visual C++ documentation of the function CreateFont(). It is related to the size parameter by the default GDI aspect ratio and the natural aspect ratio of the chosen font.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;font_angle&#039;&#039; parameter allows you to modify the baseline angle of text in 0.1 degree increments anti-clockwise.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;interlaced&#039;&#039; parameter when enabled reduces flicker from sharp fine vertical transitions on interlaced displays. It applies a mild vertical blur by increasing the window for the anti-aliaser to include 0.5 of the pixel weight from the lines above and below.&lt;br /&gt;
&lt;br /&gt;
The short form (with all default parameters) is useful when you don&#039;t really care what the subtitle looks like as long as you can see it--for example, when you&#039;re using [[StackVertical]] and its ilk to display several versions of a frame at once, and you want to label them to remember which is which. &lt;br /&gt;
&lt;br /&gt;
This filter is used internally by AviSynth for the [[Version]] command and for reporting error messages, and the subtitling apparatus is also used by [[ShowFrameNumber]].&lt;br /&gt;
&lt;br /&gt;
===Default values===&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;clip&#039;&#039;&lt;br /&gt;
::: last&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;text&#039;&#039;&lt;br /&gt;
::: no default, must be specified&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;x&#039;&#039;&lt;br /&gt;
::: 8 if align=1,4,7 or none; -1 if align=2,5,8; or width-8 if align=3,6,9&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;y&#039;&#039;&lt;br /&gt;
::: &#039;&#039;size&#039;&#039; if align=4,5,6 or none; 0 if align=7,8,9; or height-1 if align=1,2,3&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;first_frame&#039;&#039;&lt;br /&gt;
::: 0&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;last_frame&#039;&#039;&lt;br /&gt;
::: framecount(&#039;&#039;clip&#039;&#039;)-1&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;font&#039;&#039;&lt;br /&gt;
::: &amp;quot;Arial&amp;quot;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;size&#039;&#039;&lt;br /&gt;
::: 18.0&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;text_color&#039;&#039;&lt;br /&gt;
::: $00FFFF00 &amp;lt;full opaque yellow&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;halo_color&#039;&#039;&lt;br /&gt;
::: 0 &amp;lt;full opaque black&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;align&#039;&#039;&lt;br /&gt;
::: Normally 4 &amp;lt;left and baseline&amp;gt;; if x=-1, then 5 &amp;lt;horizontal center and baseline&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;spc&#039;&#039;&lt;br /&gt;
::: 0 &amp;lt;font spacing unchanged&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;lsp&#039;&#039;&lt;br /&gt;
::: &amp;lt;multiline is not enabled&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;font_width&#039;&#039;&lt;br /&gt;
::: 0 &amp;lt;system default&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;font_angle&#039;&#039;&lt;br /&gt;
::: 0.0 degrees&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;interlaced&#039;&#039;&lt;br /&gt;
::: false&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Examples===&lt;br /&gt;
&lt;br /&gt;
 # Some text in the center of the clip:&lt;br /&gt;
 AviSource(&amp;quot;D:\clip.avi&amp;quot;)&lt;br /&gt;
 Subtitle(&amp;quot;Hello world!&amp;quot;, align=5)&lt;br /&gt;
&lt;br /&gt;
 # Some text in the upper right corner of the clip with specified font, size and color:&lt;br /&gt;
 AviSource(&amp;quot;D:\clip.avi&amp;quot;)&lt;br /&gt;
 Subtitle(&amp;quot;Hello world!&amp;quot;, font=&amp;quot;georgia&amp;quot;, size=24, text_color=$ff0000, align=9)&lt;br /&gt;
&lt;br /&gt;
 # Prints text on multiple lines&lt;br /&gt;
 # without any text halo border.&lt;br /&gt;
 BlankClip()&lt;br /&gt;
 Subtitle( \&lt;br /&gt;
   &amp;quot;Some text on line 1\\nMore text on line 1\n&amp;quot; + \&lt;br /&gt;
   &amp;quot;Some text on line 2&amp;quot;, \&lt;br /&gt;
          lsp=10, halo_color=$ff000000)&lt;br /&gt;
 &lt;br /&gt;
 # It results in:&lt;br /&gt;
 Some text on line 1\nMore text on line 1&lt;br /&gt;
 Some text on line 2&lt;br /&gt;
&lt;br /&gt;
 # Use String() to display values of functions.&lt;br /&gt;
 AviSource(&amp;quot;D:\clip.avi&amp;quot;)&lt;br /&gt;
 Subtitle(&amp;quot;Width=&amp;quot; + String(Width()))&lt;br /&gt;
&lt;br /&gt;
===Changes===&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| v2.60&lt;br /&gt;
| position (x,y) can be float (previously int) (with 0.125 pixel granularity).&lt;br /&gt;
|-&lt;br /&gt;
| v2.58&lt;br /&gt;
| Added font_width, font_angle, interlaced and alpha color blending.&lt;br /&gt;
|-&lt;br /&gt;
| v2.57&lt;br /&gt;
| Added multi-line text and line spacing parameter.&lt;br /&gt;
|-&lt;br /&gt;
| v2.07&lt;br /&gt;
| Added &#039;&#039;align&#039;&#039; and &#039;&#039;spc&#039;&#039; parameters. Setting y=-1 calculates vertical center (alignment unaffected). Default &#039;&#039;x&#039;&#039; and &#039;&#039;y&#039;&#039; values dependent on alignment (previously x=8, y=&#039;&#039;size&#039;&#039;).&lt;br /&gt;
|-&lt;br /&gt;
| v1.00&lt;br /&gt;
| Setting x=-1 uses horizontal center and center alignment (undocumented prior to v2.07).&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===See also===&lt;br /&gt;
&lt;br /&gt;
There are [[External_filters#Subtitling|external subtitling filters]] that display SRT, SSA, and other format subtitle files or offer more elaborate formatting.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=SmoothDeinterlaceFunctions&amp;diff=937</id>
		<title>SmoothDeinterlaceFunctions</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=SmoothDeinterlaceFunctions&amp;diff=937"/>
		<updated>2010-08-23T14:27:59Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: specific link&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;SmoothDeinterlace is Xesdeeni2001&#039;s port of Gunnar Thalin&#039;s &#039;Smooth&#039; deinterlacer for VirtualDub. &lt;br /&gt;
&lt;br /&gt;
It is hosted on [http://www.guthspot.se/video/AVSPorts/SmoothDeinterlacer/ Gunnar Thalin&#039;s webpage].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
One of the many cool things you can do with this filter is convert between broadcast formats with much less quality loss than would be possible using standard AviSynth filters alone. Here are some functions suggested in the documentation; feel free to use them.&lt;br /&gt;
&lt;br /&gt;
    function PAL2NTSC_DV(clip c)&lt;br /&gt;
    {&lt;br /&gt;
        c.SmoothDeinterlace(tff=false, doublerate=true)&lt;br /&gt;
        BilinearResize(720, 480)&lt;br /&gt;
        [[ChangeFPS]](59.94)&lt;br /&gt;
        SeparateFields()&lt;br /&gt;
        SelectEvery(4, 0, 3)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function NTSC2PAL_DV(clip c)&lt;br /&gt;
    {&lt;br /&gt;
        c.SmoothDeinterlace(tff=false, doublerate=true)&lt;br /&gt;
        [[BilinearResize]](720, 576)&lt;br /&gt;
        [[ConvertFPS]](50)&lt;br /&gt;
        SeparateFields()&lt;br /&gt;
        SelectEvery(4, 0, 3)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function PAL2NTSC_DVD(clip c)&lt;br /&gt;
    {&lt;br /&gt;
        c.SmoothDeinterlace(tff=true, doublerate=true)&lt;br /&gt;
        BilinearResize(720, 480)&lt;br /&gt;
        ChangeFPS(59.94)&lt;br /&gt;
        [[SeparateFields]]()&lt;br /&gt;
        SelectEvery(4, 1, 2)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function NTSC2PAL_DVD(clip c)&lt;br /&gt;
    {&lt;br /&gt;
        c.SmoothDeinterlace(tff=true, doublerate=true)&lt;br /&gt;
        BilinearResize(720, 576)&lt;br /&gt;
        ConvertFPS(50)&lt;br /&gt;
        SeparateFields()&lt;br /&gt;
        [[SelectEvery]](4, 1, 2)&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
Like what you see? Just copy the above into a script, put it in your plugins directory and start using them immediately!&lt;br /&gt;
&lt;br /&gt;
[[Category:Shared functions]]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=UnFilter&amp;diff=254</id>
		<title>UnFilter</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=UnFilter&amp;diff=254"/>
		<updated>2010-04-14T07:50:35Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: add abstract&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{FilterCat|External_filters|Adjustment_filters|Sharpeners}}&lt;br /&gt;
{{Template:FuncDef|UnFilter(clip source,  int &#039;&#039;HSharp&#039;&#039;, int &#039;&#039;VSharp&#039;&#039;) }}&lt;br /&gt;
{{Filter&lt;br /&gt;
|[http://www.trbarry.com Tom Barry]&lt;br /&gt;
|0.0.1.5&lt;br /&gt;
|[http://www.trbarry.com/UnFilter.zip UnFilter.zip]&lt;br /&gt;
|Adjustment filters&lt;br /&gt;
|[[YV12]]&lt;br /&gt;
|GPL&lt;br /&gt;
}}&lt;br /&gt;
== Abstract ==&lt;br /&gt;
UnFilter is a simple and reasonably fast Avisynth Soften/Sharpen filter.&lt;br /&gt;
&lt;br /&gt;
It implements 5-tap user adjustable horizontal and vertical filters designed to &lt;br /&gt;
(slightly) reverse previous efforts at softening or edge enhancement that are&lt;br /&gt;
common (but ugly) in DVD mastering.  Since DVDs were intended originally&lt;br /&gt;
for interlaced displays this has caused content providers to vertically filter&lt;br /&gt;
them even a bit more to hide interlacing artifacts.  They sometimes overdo&lt;br /&gt;
the edge enhancement.&lt;br /&gt;
&lt;br /&gt;
When softening it will attempt to approximate the inverse of a simple 3-tap edge&lt;br /&gt;
enhancement filter. When sharpening it will attempt to approximate the inverse&lt;br /&gt;
of a simple 3-tap softening filter.  For the math and logic involved see&lt;br /&gt;
the comments in the UnFilterALL.inc member included in zip file.&lt;br /&gt;
&lt;br /&gt;
The effects are fairly mild but be aware that excessive sharpening makes things &lt;br /&gt;
harder to compress and may bring about the dreaded &amp;quot;edge enhancement artifacts&amp;quot;&lt;br /&gt;
the people complain about in DVDs from some studios.  And while excessive &lt;br /&gt;
softness may hide noise it loses detail and generally just looks ugly. So it is&lt;br /&gt;
probably best to just try to reverse whatever has already been done to your source.&lt;br /&gt;
&lt;br /&gt;
UnFilter should run on all MMX machines or higher. It has also has some added code &lt;br /&gt;
for 3DNOW instructions for when it is running on a K6-II or higher and some SSEMMX &lt;br /&gt;
for P3 &amp;amp; Athlon.&lt;br /&gt;
&lt;br /&gt;
==Known issues and limitations==&lt;br /&gt;
&lt;br /&gt;
Assumes YUV (YUY2) or YV12 Frame Based input. Use an AVIsynth function to convert first if  needed.        &lt;br /&gt;
&lt;br /&gt;
Currently still requires the pixel width to be a multiple of 2. &lt;br /&gt;
&lt;br /&gt;
YV12 support for Avisynth 2.5 alpha release only.&lt;br /&gt;
&lt;br /&gt;
== Requires Filters ==&lt;br /&gt;
 &lt;br /&gt;
[http://www.trbarry.com/UnFilter.zip Unfilter.dll] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Parameters==&lt;br /&gt;
&lt;br /&gt;
{{ParR|HSharp|int|0|-100-100}}&lt;br /&gt;
Horizontal sharpness.  Valid values are from -100 (max softness) through zero (neutral) through +100 (max sharpness).&lt;br /&gt;
&lt;br /&gt;
{{ParR|VSharp|int|0|-100-100}}&lt;br /&gt;
Vertical sharpness.  Valid values are from -100 (max softness) through zero (neutral) through +100 (max sharpness).&lt;br /&gt;
&lt;br /&gt;
== Examples== &lt;br /&gt;
&lt;br /&gt;
Extreme sharpening&lt;br /&gt;
 LoadPlugin(&amp;quot;F:\UnFilter\UnFilter.dll&amp;quot;)&lt;br /&gt;
 Avisource(&amp;quot;D:\wherever\myfile.avi&amp;quot;)&lt;br /&gt;
 UnFilter(100,100)&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
*[http://www.trbarry.com Tom Barry&#039;s Avisynth filters]&lt;br /&gt;
*[http://forum.doom9.org/showthread.php?s=&amp;amp;threadid=28197&amp;amp;pagenumber=3 Doom9 discussion]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=YAHR&amp;diff=236</id>
		<title>YAHR</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=YAHR&amp;diff=236"/>
		<updated>2010-04-14T06:38:32Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: /* Abstract */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{FilterCat|External_filters|Restoration_filters|Dehaloers}}&lt;br /&gt;
{{Filter&lt;br /&gt;
|Didée&lt;br /&gt;
|1.0&lt;br /&gt;
|[http://avisynth.org/mediawiki/upload/f/f9/YAHR.avsi YAHR.avsi]&lt;br /&gt;
|Dehaloers&lt;br /&gt;
|&lt;br /&gt;
* YV12&lt;br /&gt;
|}}&lt;br /&gt;
&lt;br /&gt;
{{Template:FuncDef|YAHR( )}}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Y&#039;&#039;&#039;et &#039;&#039;&#039;A&#039;&#039;&#039;nother &#039;&#039;&#039;H&#039;&#039;&#039;alo &#039;&#039;&#039;R&#039;&#039;&#039;educing script&lt;br /&gt;
&lt;br /&gt;
=== Requires Filters ===&lt;br /&gt;
*[[aWarpSharp]]&lt;br /&gt;
*[[MaskTools]]&lt;br /&gt;
*[[MedianBlur]]&lt;br /&gt;
*[[MinBlur]]&lt;br /&gt;
*[[RemoveGrain]]&lt;br /&gt;
*[http://avisynth.org/mediawiki/RemoveGrain Repair.dll] part of the RemoveGrain package&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
Removes halos from overenhanced edges.&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
 [[AviSource]](&amp;quot;Blah.avi&amp;quot;)&lt;br /&gt;
 YAHR()&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
Post by Didée : [http://forum.doom9.org/showthread.php?p=1205653#post1205653 link]&lt;br /&gt;
&lt;br /&gt;
Follow the discussion in its [http://forum.doom9.org/showthread.php?p=1205653 Doom9 thread].&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=AddAudio&amp;diff=949</id>
		<title>AddAudio</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=AddAudio&amp;diff=949"/>
		<updated>2010-02-22T00:03:36Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Since [[ResampleAudio]] no longer adds empty sound to a clip when used, this workaround can no longer be used for avoiding crashes in CCE 2.50. Therefore a function has been made to add audio to a clip.&lt;br /&gt;
&lt;br /&gt;
Save the following text in a file called &amp;quot;addaudio.avsi&amp;quot; and place it in the AviSynth plugin directory:&lt;br /&gt;
&lt;br /&gt;
 function AddAudio(clip v1)&lt;br /&gt;
 {&lt;br /&gt;
   v2 = Blankclip(audio_rate=44100,sixteen_bit=true,stereo=true,length=v1.FrameCount,fps=v1.FrameRate)&lt;br /&gt;
   v1 = AudioDub(v1,v2)&lt;br /&gt;
   return v1&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
To use the script, use:&lt;br /&gt;
&lt;br /&gt;
 AddAudio()&lt;br /&gt;
&lt;br /&gt;
at the end of the script instead of the earlier ResampleAudio(44100).&lt;br /&gt;
&lt;br /&gt;
[[Category:Shared functions]]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Srestore&amp;diff=216</id>
		<title>Srestore</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Srestore&amp;diff=216"/>
		<updated>2010-01-20T05:09:45Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{FilterCat|External_filters|Restoration_filters|Deblenders}}&lt;br /&gt;
{{Filter|MOmonster|2.7e|[[Media:srestore.avsi|srestore.avsi]]|Deblenders|&lt;br /&gt;
* YV12&lt;br /&gt;
|}}&lt;br /&gt;
{{Template:FuncDef|        srestore(clip source, float &#039;&#039;frate&#039;&#039;, int &#039;&#039;dmode&#039;&#039;, &#039;&#039;omode&#039;&#039;, float &#039;&#039;blocks&#039;&#039;, int &#039;&#039;mthresh&#039;&#039;, int &#039;&#039;bthresh&#039;&#039;, bool &#039;&#039;chroma&#039;&#039;, int &#039;&#039;cache&#039;&#039;, float &#039;&#039;rr&#039;&#039;, clip &#039;&#039;dclip&#039;&#039;) }}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
[[Srestore]] is the replacement function for [[mrestore]], Cdeblend, FixBlendIVTC and DupHq from the [[R_pack]]. It is an AviSynth script function that uses conditional frame evaluation for the output calculation. Generally it was written to undo norm-conversions with blends, but the last version can be useful for decimation ratios between 5 and 1 using the &#039;&#039;frate&#039;&#039; parameter.&lt;br /&gt;
&lt;br /&gt;
Important note: Srestore can only be called one time in any script due to its use of global variables.&lt;br /&gt;
&lt;br /&gt;
== Requires Filters ==&lt;br /&gt;
*[[MaskTools2]]&lt;br /&gt;
*[[TIVTC]] Version 1.04 or higher (only for cache&amp;gt;0, not default)&lt;br /&gt;
*[[RemoveGrain]]   (only for double-blend-removal, not default)&lt;br /&gt;
*[http://forum.doom9.org/showthread.php?p=1129919#post1129919 Average]       (only for double-blend-removal, not default)&lt;br /&gt;
&lt;br /&gt;
==Parameters==&lt;br /&gt;
{{Par|frate|float|optional}}&lt;br /&gt;
You don&#039;t need to set the decimation parameters for the norm conversions restoring Pal_to_NTSC (50-&amp;gt;23.976 or 25-&amp;gt;11.988) and NTSC_to_Pal (59.94-&amp;gt;25 or 29.97-&amp;gt;12.5), but for some seldom other blend conversion (for example 29.97 back to 23.976 or 50 to 25 - DEFT). Use frate to set the wanted output-framerate. If source-framerate/frate &amp;gt;5 or &amp;lt;1 the output-framerate will be the same as the input-framerate. This can be useful if you want to have only the dup functionality of srestore.&lt;br /&gt;
&lt;br /&gt;
{{ParR|omode|string|6|0-6 or mode}}&lt;br /&gt;
Srestore can be used as blend-decimation-function, as simple deblend-function and for double-blend-removal&lt;br /&gt;
: 1   - deblend-mode 1        -&amp;gt; detected blends will be replaced with the previous frame&lt;br /&gt;
: 2   - deblend-mode 2        -&amp;gt; next frame is used instead of the detected blend&lt;br /&gt;
: 3   - deblend-mode 3        -&amp;gt; detected blends will be replaced with the neighbour that has the smaller difference&lt;br /&gt;
: 4   - deblend-mode 4        -&amp;gt; use the neighbour with the smaller blend-possibility&lt;br /&gt;
: 5   - deblend-special       -&amp;gt; outputs the one of four frames with the smallest blend-possibility&lt;br /&gt;
: &amp;gt;5  - blend-decimation      -&amp;gt; for all decimation operations&lt;br /&gt;
&lt;br /&gt;
The output-modes 1-5 are simple deblending modes, so the framerate will not change.&lt;br /&gt;
            &lt;br /&gt;
To enable the double-blend-removal you have to set a string for omode. This string decides about the postprocessing mode that is used on the restored frames:&lt;br /&gt;
: pp0 -&amp;gt;  the fastest mode, no postprocessing&lt;br /&gt;
: pp1 -&amp;gt;  use difference masking, higher quality and still good speed&lt;br /&gt;
: pp2 -&amp;gt;  use a special blurring mask on luma and chroma that reduces artefacts&lt;br /&gt;
: pp3 -&amp;gt;  combines postprocessing 1 and 2   -&amp;gt; slowest&lt;br /&gt;
&lt;br /&gt;
You can add also your own postprocessing to these modes. Just add your function like this:&lt;br /&gt;
&lt;br /&gt;
 omode=&amp;quot;pp3.blur(1)&amp;quot;		   -&amp;gt; pp3 + blurring&lt;br /&gt;
If you want to add a function with its own inputstrings use three quotation marks:&lt;br /&gt;
 omode=&amp;quot;&amp;quot;&amp;quot;pp2.deen(&amp;quot;a2d&amp;quot;)&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Important Note: Also the double-blend-removal does no decimation. It&#039;s created only for double-blends caused by blend deinterlacing of telecined sources. You have to add an decimation function for full restoring:&lt;br /&gt;
&lt;br /&gt;
 source                          #progressive&lt;br /&gt;
 srestore(dmode=-4,omode=&amp;quot;pp0&amp;quot;)&lt;br /&gt;
 decimate(cycle=5,quality=0)     #recommed decimating&lt;br /&gt;
&lt;br /&gt;
{{ParR|speed|int|9|-25-25}}&lt;br /&gt;
With the speed parameter you can set a speed-vs-detail-detection value. If you set speed=25, only one of 25 pixels (5*5) is used for the detection. Higher values result in a lower possibility of low-detail detection. Set a negative speed value for high quality and hd sources. This can improve the detection of small details.&lt;br /&gt;
&lt;br /&gt;
{{ParR|mode|int|2|1-3}}&lt;br /&gt;
With the mode parameter you can decide if chroma should be used for detection and if srestore have to merge neighboured frames or look for dups to improve output quality:&lt;br /&gt;
: 1   - simple output mode, decimation is not touched&lt;br /&gt;
: 2   - duping feature, if a frame has a dup-neighbour, that seems to have a higher quality, this one will be outputed&lt;br /&gt;
: 3   - like 2 but the duplicates will be merged&lt;br /&gt;
: &amp;gt;3  - mode 2 and 3 combined&lt;br /&gt;
By setting the compatible negative values, the chroma values will be also used for the detection.&lt;br /&gt;
Note: The double-blend-removal does not use this parameter (-&amp;gt; only mode 1 or -1).&lt;br /&gt;
&lt;br /&gt;
{{ParR|thresh|int|22|12-44}}&lt;br /&gt;
The detection of srestore is pretty stable, but the threshold is still important to weight the detection influence. Use small values for sources with little temporal artefacts (bobbing effect, aliasing, blocks, noise, ...) and higher values for the opposite case.&lt;br /&gt;
&lt;br /&gt;
{{ParR|cache|int|-1|-1-10}}&lt;br /&gt;
With cache&amp;gt;=0 srestore use the RequestLinear function (TIVTC) to be more compatible with non-linear requesting (codec or other functions). Best way to use srestore is to do a lossless first pass right after calling srestore and do all other filtering and the final encoding in a second pass. If you do not have enough space to do a lossless pass and you cannot avoid non-linear frame requesting and the pattern of the source is pretty unstable set cache around 5-10, but keep in mind that this can increase memory usage.&lt;br /&gt;
    			&lt;br /&gt;
{{Par|dclip|clip|input}}&lt;br /&gt;
The &#039;&#039;&#039;d&#039;&#039;&#039;etection &#039;&#039;&#039;clip&#039;&#039;&#039; can be used to improve (deblock, smooth, ...) and speed-up blend and motion detection. The selected clip is only used for detection and not for output, so it does not affect the output quality. &lt;br /&gt;
If you use a high quality deinterlacing on the source you can speed up the detection by using a faster deinterlacing function (third code example) for the detection clip.&lt;br /&gt;
It&#039;s recommended to crop the bobbed source (deinterlace BEFORE cropping!) to avoid the detection influence of the bobbing borders (second code example).&lt;br /&gt;
&lt;br /&gt;
== Examples== &lt;br /&gt;
&lt;br /&gt;
bobbed (or progressive) source&lt;br /&gt;
 srestore()&lt;br /&gt;
&lt;br /&gt;
or:&lt;br /&gt;
 ord = last.getparity() ? 1 : 0&lt;br /&gt;
 leakkernelbob(ord,4,true,true)&lt;br /&gt;
 srestore(dclip=last.crop(8,16,-8,-24))&lt;br /&gt;
&lt;br /&gt;
or:&lt;br /&gt;
 d = last.bob(-0.2,0.6).reduceflicker(strength=1)&lt;br /&gt;
 tdeint(mode=1)   #or for example yadif(mode=1)&lt;br /&gt;
 srestore(mode=4,dclip=d)&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
*[http://forum.doom9.org/showthread.php?t=95924 Discussion thread] at [http://forum.doom9.org/ Doom9&#039;s Forum]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=C_deblend&amp;diff=212</id>
		<title>C deblend</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=C_deblend&amp;diff=212"/>
		<updated>2010-01-20T04:27:20Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: /* Parameters */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{FilterCat|External_filters|Restoration_filters|Deblenders}}&lt;br /&gt;
{{Filter|MOmonster|1.1b|[[Media:Cdeblend.avs|Cdeblend.avs]]|Deblenders|&lt;br /&gt;
* YV12&lt;br /&gt;
|}}&lt;br /&gt;
{{Template:FuncDef|Cdeblend(clip input, int &#039;&#039;omode&#039;&#039;, float &#039;&#039;bthresh&#039;&#039;, &#039;&#039;mthresh&#039;&#039;, &#039;&#039;xr&#039;&#039;, &#039;&#039;yr&#039;&#039;, bool &#039;&#039;fnr&#039;&#039;, clip &#039;&#039;dclip&#039;&#039;) }}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
Cdeblend is a simple blend replacing function like unblend or removeblend.&lt;br /&gt;
Now superseded by [[Srestore]].&lt;br /&gt;
&lt;br /&gt;
=== Requires Filters ===&lt;br /&gt;
*[[Removegrain|RemoveGrain]] 1.x, for fnr=true.&lt;br /&gt;
*[[MaskTools2]]&lt;br /&gt;
&lt;br /&gt;
== Parameters ==&lt;br /&gt;
{{ParR|omode|int|0|0-4}}&lt;br /&gt;
Stands for the output mode. There are five different omodes:&lt;br /&gt;
*omode 0 -&amp;gt;	The previous frame will be duplicated to avoid a blend. (Default.)&lt;br /&gt;
*omode 1 -&amp;gt;	The next frame is used instead of a blend.&lt;br /&gt;
*omode 2 -&amp;gt;	Like omode 0 but with some double-blend detection (only without missing fields)&lt;br /&gt;
*omode 3 -&amp;gt;	A special mode for 12fps sources.&lt;br /&gt;
*omode 4 -&amp;gt;	Does nothing with the source. It just subtitles the blend factor.&lt;br /&gt;
&lt;br /&gt;
{{ParR|bthresh|float|0.1|0-2.0}}&lt;br /&gt;
For omode 0 and 1 bthresh will be just compared with the calculated blend factor. If the blend factor is higher a blend is detected. Omode 3 uses this threshold to detect clears. If blendfactor&amp;lt;-bthresh the frame will be output also if there is another frame with a smaller blendfactor. This can give a better motion.&lt;br /&gt;
&lt;br /&gt;
{{ParR|mthresh|float|0.6|0.3-1.6}}&lt;br /&gt;
Used for (m)otion (thresh)olding. It regulates the blend detection of frames with small pixel value differences. A better quality of the source allows lower values and a more accurate detection.&lt;br /&gt;
&lt;br /&gt;
{{ParR|xr,yr|float|1,5,2.0|1.0-4.0}}&lt;br /&gt;
The scaled detection radius (xr &amp;amp; yr) blurs the internal detection clip and can speed up the function a little bit.&lt;br /&gt;
&lt;br /&gt;
{{Par|fnr|bool|false}}&lt;br /&gt;
With fnr=true you enable a (f)ast (n)oise (r)eduction. It&#039;s sometimes useful for noisy sources and typical area motion (anime). Don&#039;t use a too big radius if you enable this feature and don&#039;t use it on very clean sources (speed decreasing is not the only negative effect).	&lt;br /&gt;
&lt;br /&gt;
{{Par|dclip|clip|input}}&lt;br /&gt;
The &#039;&#039;&#039;d&#039;&#039;&#039;etection&#039;&#039;&#039;clip&#039;&#039;&#039; can be set to improve the blend detection (cleaning the clip before).&lt;br /&gt;
This clip is only used for the blend detection and not for output.&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Avisource(&amp;quot;blah.avi&amp;quot;)&lt;br /&gt;
Cdeblend()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Avisource(&amp;quot;blah.avi&amp;quot;)&lt;br /&gt;
tdeint(mode=1)&lt;br /&gt;
c = last.crop(8,16,-8,-8)&lt;br /&gt;
Cdeblend(omode=1,dclip=c)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Links==&lt;br /&gt;
Download [[Media:Cdeblend.avs|Cdeblend.avs]]&amp;lt;br/&amp;gt;&lt;br /&gt;
Follow the discussion here [http://forum.doom9.org/showthread.php?t=95924 Doom9 forum]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=SuperEQ&amp;diff=554</id>
		<title>SuperEQ</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=SuperEQ&amp;diff=554"/>
		<updated>2008-08-13T07:47:25Z</updated>

		<summary type="html">&lt;p&gt;AlanHK: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Func2Def|SuperEq(clip, string filename)|SuperEq(clip, float &#039;&#039;band1&#039;&#039; [, float &#039;&#039;band2&#039;&#039;, ..., float &#039;&#039;band18&#039;&#039;])}}&lt;br /&gt;
&lt;br /&gt;
Shibatch Super Equalizer is a graphic and parametric equalizer plugin for winamp. This plugin uses 16383th order FIR filter with FFT algorithm. Its equalization is very precise. Equalization setting can be done for each channel separately. SuperEQ is originally written by [http://shibatch.sourceforge.net/ Naoki Shibata].&lt;br /&gt;
&lt;br /&gt;
SuperEQ requires a [http://www.foobar2000.org foobar2k] equalizer setting (.feq) file.  The equalizer can be found in foobar&#039;s DSPManager, and settings are adjusted and saved from there as well.&lt;br /&gt;
&lt;br /&gt;
A .feq file is a text file with a number on each line.&lt;br /&gt;
Each value controls the amplification in decibels of each of 18 frequency bands.&lt;br /&gt;
The boundaries between bands lie on the following frequencies:&lt;br /&gt;
&lt;br /&gt;
# 65 Hz&lt;br /&gt;
# 92 Hz&lt;br /&gt;
# 131 Hz&lt;br /&gt;
# 185 Hz&lt;br /&gt;
# 262 Hz&lt;br /&gt;
# 370 Hz&lt;br /&gt;
# 523 Hz&lt;br /&gt;
# 740 Hz&lt;br /&gt;
# 1046 Hz&lt;br /&gt;
# 1480 Hz&lt;br /&gt;
# 2093 Hz&lt;br /&gt;
# 2960 Hz&lt;br /&gt;
# 4186 Hz&lt;br /&gt;
# 5920 Hz&lt;br /&gt;
# 8372 Hz&lt;br /&gt;
# 11839 Hz&lt;br /&gt;
# 16744 Hz&lt;br /&gt;
(adapted from avisynth/src/audio/supereq.h)&lt;br /&gt;
&lt;br /&gt;
For example, the first line of the file controls 0 to 65 Hz, and the sixth controls 262 to 370 Hz.&lt;br /&gt;
&lt;br /&gt;
These frequencies are the frequencies of C and F# in the modern equal tempered scales.&lt;br /&gt;
The lowest is the C two octaves below middle C.&lt;br /&gt;
&lt;br /&gt;
Some preset settings (Equalizer Presets.zip) can be found in your \AviSynth25\Examples folder.&lt;br /&gt;
&lt;br /&gt;
In v2.60, a custom band setting (band1, band2, ...) is added to allow all 18 bands to be set within your script (instead of within your preset file). The values should be specified in decibels (float).&lt;br /&gt;
&lt;br /&gt;
This plugin is optimized for processors which have cache equal to or greater than 128k bytes (16383*2*sizeof(float) = 128k). This plugin won&#039;t work efficiently with K6 series processors (buy Athlon!!!).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Parameter:&#039;&#039;&#039;&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|- &lt;br /&gt;
| filename&lt;br /&gt;
| The foobar2k equalizer preset file to apply.&lt;br /&gt;
|- &lt;br /&gt;
| band1-band18&lt;br /&gt;
| Allows to set all bands within your script (in dB).&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 # Apply &amp;quot;Loudness&amp;quot; filter from the Equalizer Presets above:&lt;br /&gt;
 SuperEq(&amp;quot;C:\Equalizer Presets\Loudness.feq&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Changes:&#039;&#039;&#039;&lt;br /&gt;
{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| v2.60&lt;br /&gt;
| Added custom band setting to allow all 16 bands to be set from script.&lt;br /&gt;
|- &lt;br /&gt;
| v2.54&lt;br /&gt;
| Initial Release.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Some parts of SuperEQ are: &amp;lt;br&amp;gt;&lt;br /&gt;
Copyright © Naoki Shibata.&lt;br /&gt;
&lt;br /&gt;
Other parts are: &amp;lt;br&amp;gt;&lt;br /&gt;
Copyright © 2001-2003, Peter Pawlowski&lt;br /&gt;
All rights reserved.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>AlanHK</name></author>
	</entry>
</feed>