Yadif: Difference between revisions

From Avisynth wiki
Jump to navigationJump to search
m 1 revision
overhaul
Line 1: Line 1:
Port of YADIF (Yet Another DeInterlacing Filter) from MPlayer by Michael Niedermayer (http://www.mplayerhq.hu). It checks pixels of previous, current and next frames to re-create the missed field by some local adaptive method (edge-directed interpolation) and uses spatial check to prevent most artifacts.
{{FilterCat|External_filters|Restoration_filters|Deinterlacers}}
 
[[Category:Plugins]]
 
{{Filter3
 
| {{Author/Fizick}}
== Syntax and parameters ==
| v1.7
| [http://avisynth.org.ru/yadif/yadif17.zip yadif17.zip]
| Deinterlacing
| [http://www.gnu.org/licenses/gpl-2.0.txt GPLv2]
|6=[http://forum.doom9.org/showthread.php?t=124284 Doom9 Thread]
}}
<br>
== Description ==
:Port of YADIF (Yet Another DeInterlacing Filter) from [http://www.mplayerhq.hu MPlayer] by Michael Niedermayer. It check pixels of previous, current and next frames to re-create the missed field by some local adaptive method (edge-directed interpolation) and uses spatial check to prevent most artifacts.
<br>


== Requirements ==
:- AviSynth 2.5.8 or later
:- Supported color formats: [[YV12]]
<br>


''Yadif (clip, int "mode", int "order")''
== [[Script variables|Syntax and Parameters]] ==
:{{Template:FuncDef|Yadif (clip, int "mode", int "order", bool "planar", int "opt")}}
<br>
::{{Par2| |clip| }}
:::Input clip
<br>
::{{Par2|mode|int|0}}
::::*0 : single frame rate, temporal and spatial interlacing check (default).
::::*1 : double frame rate, temporal and spatial interlacing check.
::::*2 : single frame rate, skips spatial interlacing check.
::::*3 : double frame rate, skips spatial interlacing check.
<br>
::{{Par2|order|int|1}}
::::*-1 : field order as Avisynth assumes (default).
::::*0 : bottom field first
::::*1 : top field first
<br>
::{{Par2|planar|bool|false}}
::::*false : usual [[YV12]] colorspace (default); if input clip is YV12 this parameter is silently ignored.
::::*true : flag for (hacked) planar YUY2 color format of input and output clips, compatible with Interleaved2planar and Planar2Interleaved functions from the RemoveGrain ([[RemoveGrain_v0.9/SSETools|SSETools]]) plugin.
<br>
::{{Par2|opt|int|0}}
::::*-1 : CPU optimization - auto (default).
::::*0 : slow C version.
::::*1 : [[ISSE|Integer SSE]]
::::*2 : [[SSE2]]
::::*3 : [[SSSE3]] (some)
<br>


mode = 0 : temporal and spatial interlacing check (default).
== Examples ==
Yadif with default settings:
[[AviSource]]("blah.avi")
Yadif(mode=0, order=-1, planar=false, opt=-1)


= 1 : double framerate (bob), temporal and spatial interlacing check.
<br>
 
== Changelog ==
= 2 : skips spatial interlacing check.
Version      Date            Changes<br>
 
<br>
= 3 : double framerate (bob), skips spatial interlacing check.
== Archived Downloads ==
 
{| class="wikitable" border="1"; width="400px"
order = -1 : field order as Avisynth assumes (default).
|-
 
!!width="100px"| Version
= 0 : Bottom field first.
!!width="150px"| Download
 
!!width="150px"| Mirror
= 1 : Top field first.
|-
 
!v1.7
 
|[http://avisynth.org.ru/yadif/yadif17.zip yadif17.zip]
 
|[http://avisynth.nl/users/fizick/yadif/yadif17.zip yadif17.zip]
== Features and limitations ==
|}
 
<br>
 
== External Links ==
Implemented as Avisynth C-plugin (not regular Avisynth plugin).
*[http://forum.doom9.org/showthread.php?t=124284 Doom9 Forum] - Yadif discussion.
Must be loaded with Load_Stdcall_plugin("yadif.dll") or LoadCplugin("yadif.dll") (not LoadPlugin !). Do not use autoloading. (Note: in Avisynth v2.5.7 there is no need for explicit loading of Avisynth_c.dll by user for such plugins.)
*[http://avisynth.org.ru/yadif/yadif.html avisynth.org.ru] - Official homepage and documentation.
 
<br>
Tested in Avisynth v2.5.7 (probably works with v2.5.6 and above).
<br>
 
<br>
Field parity of source clip must be properly set (use AssumeTFF, AssumeBFF).
-----------------------------------------------
 
'''Back to [[External_filters#Deinterlacing|External Filters]] &larr;'''
Very fast. Assembler SSEMMX optimization from mplayer (compiled with MinGW GCC).
 
YUY2, Planar YV12 color format only.
 
[http://forum.doom9.org/showthread.php?t=124284 Discussion]
 
[[Category:Plugins]]

Revision as of 05:47, 16 August 2014

Abstract
Author Fizick
Version v1.7
Download yadif17.zip
Category Deinterlacing
License GPLv2
Discussion Doom9 Thread


Description

Port of YADIF (Yet Another DeInterlacing Filter) from MPlayer by Michael Niedermayer. It check pixels of previous, current and next frames to re-create the missed field by some local adaptive method (edge-directed interpolation) and uses spatial check to prevent most artifacts.


Requirements

- AviSynth 2.5.8 or later
- Supported color formats: YV12


Yadif (clip, int "mode", int "order", bool "planar", int "opt")


clip   =
Input clip


int  mode = 0
  • 0 : single frame rate, temporal and spatial interlacing check (default).
  • 1 : double frame rate, temporal and spatial interlacing check.
  • 2 : single frame rate, skips spatial interlacing check.
  • 3 : double frame rate, skips spatial interlacing check.


int  order = 1
  • -1 : field order as Avisynth assumes (default).
  • 0 : bottom field first
  • 1 : top field first


bool  planar = false
  • false : usual YV12 colorspace (default); if input clip is YV12 this parameter is silently ignored.
  • true : flag for (hacked) planar YUY2 color format of input and output clips, compatible with Interleaved2planar and Planar2Interleaved functions from the RemoveGrain (SSETools) plugin.


int  opt = 0
  • -1 : CPU optimization - auto (default).
  • 0 : slow C version.
  • 1 : Integer SSE
  • 2 : SSE2
  • 3 : SSSE3 (some)


Examples

Yadif with default settings:

AviSource("blah.avi")
Yadif(mode=0, order=-1, planar=false, opt=-1)


Changelog

Version      Date            Changes


Archived Downloads

Version Download Mirror
v1.7 yadif17.zip yadif17.zip






Back to External Filters