From Avisynth wiki
Jump to: navigation, search
Author Tom Barry
Category Deinterlacing
License GPLv2
Discussion Doom9 Thread



TomsMoComp is a filter that uses motion compensation and adaptive processing to deinterlace video sources.


Syntax and Parameters

TomsMoComp (clip, int, int, int)

clip   =
Input clip.
int   =
TopFirst: assume the top field, lines 0,2,4,... should be displayed first. You may have to look at a few frames to see which looks best.
  • -1 : automatically pick up whatever AviSynth reports
  • 0 : BottomFirst
  • 1 : TopFirst
int   =
SearchEffort: determines how much effort (CPU time) will be used to find moved pixels. Valid range is from -1 to 30, with 0 being practically just a smarter bob and 30 being fairly CPU intensive. Higher values are also more prone to artifacts.
A value of -1 means the TomsMoComp filter will not deinterlace but instead assume you already have progressive frames but want to double the vertical size. Useful for low bit rate captures that are hard to IVTC/deinterlace or where you have just kept the even fields for some other reason.
int   =
  • 0 : off (default)
  • 1 : on - filter will very slightly blend each pair of horizontal lines together. This loses only a small amount of vertical resolution but is probably a good idea as it can somewhat hide remaining deinterlace artifacts and will probably also make you clip compress a bit better.

Note: these parameters are all unnamed and do not have defaults, each value must be specified.


We've asked Tom to include a proper 60fps deinterlacer in his wonderful TomsMoComp, but until then you'll have to make do with TomsBob.

This function does uses the special '-1' mode of TomsMoComp for jaggy-free upscaling. It also requires the plugin SimpleResize, obviously, as part of the step to remove bobbing.

   function TomsBob (clip c) 
       c = c.SeparateFields.TomsMoComp(0,-1,0).SimpleResize(c.width,c.height+1) 

       # add this if your clip starts on a half-frame (e.g. a top-field in a BottomFirst clip) 
       c = c.Trim(1,0) 

       # invert these for TopFirst source material 
       bottom = c.SelectEven()
       top = c.SelectOdd()

       bottom = bottom.Crop(0,1,0,0) 
       top = top.Crop(0,0,0,-1) 
       return Interleave(bottom, top) 

Archived Downloads

Version Download Mirror Mirror 2

External Links

Back to External Filters

Personal tools