<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.selur.net/index.php?action=history&amp;feed=atom&amp;title=Vapoursynth_Fix_combed_with_deinterlacer</id>
	<title>Vapoursynth Fix combed with deinterlacer - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.selur.net/index.php?action=history&amp;feed=atom&amp;title=Vapoursynth_Fix_combed_with_deinterlacer"/>
	<link rel="alternate" type="text/html" href="https://wiki.selur.net/index.php?title=Vapoursynth_Fix_combed_with_deinterlacer&amp;action=history"/>
	<updated>2026-11-19T05:56:01Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.2</generator>
	<entry>
		<id>https://wiki.selur.net/index.php?title=Vapoursynth_Fix_combed_with_deinterlacer&amp;diff=528&amp;oldid=prev</id>
		<title>Selur: New filter page (via create-page on MediaWiki MCP Server)</title>
		<link rel="alternate" type="text/html" href="https://wiki.selur.net/index.php?title=Vapoursynth_Fix_combed_with_deinterlacer&amp;diff=528&amp;oldid=prev"/>
		<updated>2026-11-16T08:49:23Z</updated>

		<summary type="html">&lt;p&gt;New filter page (via create-page on MediaWiki MCP Server)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;div style=&amp;quot;float:right; margin:0 0 1em 1em;&amp;quot;&amp;gt;__TOC__&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Fix combed with deinterlacer&amp;#039;&amp;#039;&amp;#039; replaces every frame that is still combed after inverse telecine with the output of a deinterlacer; frames without combing stay untouched.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;Filtering → (De-)Interlace/Telecine → Extras&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Vapoursynth_FixCombedDeinterlacer.png|none|Fix combed with deinterlacer controls in Hybrid]]&lt;br /&gt;
&lt;br /&gt;
== What it does ==&lt;br /&gt;
After field matching and decimation some frames can remain combed, for example in video sections, at bad edits or with orphaned fields. A combing detector (IsCombed) checks each frame; where it finds combing, the deinterlaced frame is taken instead of the original. It is an option of [[Vapoursynth VIVTC|VIVTC]] only.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Control !! Parameter !! Range / values !! Hybrid default !! Meaning&lt;br /&gt;
|-&lt;br /&gt;
| (group check box) || – || on/off || off || Enables the fix.&lt;br /&gt;
|-&lt;br /&gt;
| Deinterlacer || – || QTGMC fast / medium / slow / Very Slow, NNEDI3 || QTGMC fast || Deinterlacer for the replacement frames: [[Vapoursynth QTGMC|QTGMC]] with the named preset, or NNEDI3.&lt;br /&gt;
|-&lt;br /&gt;
| Threshold || cthresh || 1 – 256 || 6 || Combing strength threshold.&lt;br /&gt;
|-&lt;br /&gt;
| Block (X/Y) || blockx / blocky || 4 – 2048 || 16 / 16 || Size of the detection window.&lt;br /&gt;
|-&lt;br /&gt;
| MI || mi || 0 – Block X × Block Y || 64 || Combed pixels per block needed for a frame to count as combed.&lt;br /&gt;
|-&lt;br /&gt;
| Metric || metric || 0 – 1 || 0 || Combing metric.&lt;br /&gt;
|-&lt;br /&gt;
| Chroma || chroma || on/off || off || Include chroma in the detection.&lt;br /&gt;
|-&lt;br /&gt;
| Tools || – || nnedi3 family, or the QTGMC families || – || Implementations for the chosen deinterlacer.&lt;br /&gt;
|}&lt;br /&gt;
The detection values are only written when they differ from the defaults (Hybrid&amp;#039;s defaults are the plugin&amp;#039;s).&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
VIVTC with default settings and Fix combed with deinterlacer enabled (default settings) on an 8-bit YUV 4:2:0 telecined source (1920x1080, 29.97 fps, detected as top field first):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
clip2clip = clip&lt;br /&gt;
clip2clip = qtgmc.QTGMC(Input=clip2clip, Preset=&amp;quot;fast&amp;quot;, tools={&amp;#039;mv&amp;#039;: &amp;#039;mvutensils&amp;#039;, &amp;#039;expr&amp;#039;: &amp;#039;akarin&amp;#039;, &amp;#039;nnedi3&amp;#039;: &amp;#039;znedi3&amp;#039;, &amp;#039;eedi3&amp;#039;: &amp;#039;vszip&amp;#039;, &amp;#039;dfttest&amp;#039;: &amp;#039;neo_fft&amp;#039;, &amp;#039;nlmeans&amp;#039;: &amp;#039;knlm&amp;#039;, &amp;#039;bm3d&amp;#039;: &amp;#039;bm3d&amp;#039;, &amp;#039;rg&amp;#039;: &amp;#039;zsmooth&amp;#039;, &amp;#039;median&amp;#039;: &amp;#039;zsmooth&amp;#039;, &amp;#039;fft3d&amp;#039;: &amp;#039;neo_fft&amp;#039;, &amp;#039;grain&amp;#039;: &amp;#039;noise&amp;#039;}, TFF=True, FPSDivisor=2)&lt;br /&gt;
clip = core.vivtc.VFM(clip, order=1)&lt;br /&gt;
# VDecimate helper function &lt;br /&gt;
def postprocess(n, f, clip, deinterlaced):&lt;br /&gt;
  if f.props[&amp;#039;_Combed&amp;#039;] &amp;gt; 0:&lt;br /&gt;
    return deinterlaced&lt;br /&gt;
  else:&lt;br /&gt;
    return clip&lt;br /&gt;
clip = core.std.FrameEval(clip=clip, eval=functools.partial(postprocess, clip=clip, deinterlaced=clip2clip), prop_src=clip)&lt;br /&gt;
clip = core.vivtc.VDecimate(clip) # new fps: 23.976&lt;br /&gt;
# Making sure content is perceived as frame based&lt;br /&gt;
clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_PROGRESSIVE) # scan type: progressive&lt;br /&gt;
# Fix combed frames&lt;br /&gt;
# adding helper function&lt;br /&gt;
def conditionalDeint(n, f, orig, deint):&lt;br /&gt;
    if f.props._Combed:&lt;br /&gt;
        return deint&lt;br /&gt;
    else:&lt;br /&gt;
        return orig&lt;br /&gt;
clipDeint = qtgmc.QTGMC(Preset=&amp;quot;fast&amp;quot;, Input=clip, TFF=True, FPSDivisor=2, tools={&amp;#039;mv&amp;#039;: &amp;#039;mvutensils&amp;#039;, &amp;#039;expr&amp;#039;: &amp;#039;akarin&amp;#039;, &amp;#039;nnedi3&amp;#039;: &amp;#039;znedi3&amp;#039;, &amp;#039;eedi3&amp;#039;: &amp;#039;vszip&amp;#039;, &amp;#039;dfttest&amp;#039;: &amp;#039;neo_fft&amp;#039;, &amp;#039;nlmeans&amp;#039;: &amp;#039;knlm&amp;#039;, &amp;#039;bm3d&amp;#039;: &amp;#039;bm3d&amp;#039;, &amp;#039;rg&amp;#039;: &amp;#039;zsmooth&amp;#039;, &amp;#039;median&amp;#039;: &amp;#039;zsmooth&amp;#039;, &amp;#039;fft3d&amp;#039;: &amp;#039;neo_fft&amp;#039;, &amp;#039;grain&amp;#039;: &amp;#039;noise&amp;#039;})&lt;br /&gt;
clipCombProps = core.iscombed.IsCombed(clip)&lt;br /&gt;
clip = core.std.FrameEval(clip, functools.partial(conditionalDeint, orig=clip, deint=clipDeint), clipCombProps)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== How Hybrid calls it ==&lt;br /&gt;
* Runs on the decimated clip after VIVTC (and after [[Vapoursynth Fix Telecined Fades|Fix Telecined Fades]]).&lt;br /&gt;
* Field order: the deinterlacer uses the source&amp;#039;s field order (detected scan type or [[Overwrite input scan type]]); top field first when it is unknown.&lt;br /&gt;
* QTGMC runs at single rate, so each replacement frame shows the same moment as the frame it replaces. Frame rate and frame count do not change.&lt;br /&gt;
* Works on 8–16-bit YUV.&lt;br /&gt;
&lt;br /&gt;
== Background ==&lt;br /&gt;
IsCombed is HolyWu&amp;#039;s VapourSynth plugin; it marks combed frames in the frame properties, which a frame-by-frame selection then uses. In AviSynth the same idea is usually built from TIVTC&amp;#039;s IsCombedTIVTC and a conditional filter.&lt;br /&gt;
&lt;br /&gt;
== Sources ==&lt;br /&gt;
* [https://github.com/HolyWu/VapourSynth-IsCombed VapourSynth-IsCombed README]&lt;br /&gt;
* Hybrid&amp;#039;s tooltips&lt;br /&gt;
&lt;br /&gt;
[[Category:Vapoursynth Filters]]&lt;/div&gt;</summary>
		<author><name>Selur</name></author>
	</entry>
</feed>