[FFmpeg-user] ffmpeg architecture question

Mark Filipak markfilipak.windows+ffmpeg at gmail.com
Sun Apr 19 04:43:04 EEST 2020


On 04/18/2020 08:44 PM, Carl Eugen Hoyos wrote:
> Am Sa., 18. Apr. 2020 um 21:32 Uhr schrieb Mark Filipak
> <markfilipak.windows+ffmpeg at gmail.com>:
> 
>> Regarding deinterlace, Carl Eugen, I'm not trying to deinterlace.
> 
> pp=linblenddeint is a (very simple) deinterlacer, once upon a
> time it was the preferred deinterlacer for some users, possibly
> because of its low performance requirements.
> telecine=pattern=5 produces one interlaced frame out of five
> (assuming non-static input).

Well, you see, I don't call frames 2 7 12 17 ... of the 55 telecine "interlaced". I have been 
calling them "combed", but I do so simply because, 1, according to the MPEG spec they are not 
interlaced, and 2, there's no established term for them. Perhaps there is a better term than 
"combed", but I don't know it. I do know that according to the MPEG spec, "interlaced" is not the 
correct term. Applying "interlace" to both 1/framerate & 1/24 second temporal line differences 
confuses novices regarding what interlace actually is. That confusion leads to a cascade of 
confusion regarding many, many other processes (in ffmpeg and elsewhere) in which the terms 
"interlace" and "deinterlace" are used indiscriminately.

> Carl Eugen
> 
> PS:
> Note that you have a different definition of "interlaced" than
> FFmpeg due to the fact that you only think of analogue video
> transmission which FFmpeg does not support. FFmpeg can
> only deal with digital video frames, so "interlace" within
> FFmpeg is not a process but a property of (some) frames. I
> believe you call this property "combing".
> Or in other words: FFmpeg does not offer any explicit
> "deinterlacing" capabilities, only different filters for decombing
> that we call deinterlacers (like linblenddeint, bwdif and yadif).

Carl Eugen, you hit the nail on the head!

The MPEG spec defines interlace as 1/fieldrate. To the best of my knowledge, the temporal difference 
between odd/even lines in the "combed" frame(s) of a telecine (any telecine) is 1/24 sec (not 
1/fieldrate). I know that most folks call that "interlace", but trust me, applying the same term to 
two quite different phenomena is one of the things that confuses novices.

To clarify: I don't think of analog video transmission. To the best of my knowledge, when a vintage 
TV program is mastered to DVD (or presumably to BD though I've not encountered one), the analog 
tapes are digitized and packaged as 1/framerate interlaced fields. That's where I enter the picture. 
Though it is true that I date from the time of analog TV, and though it's true that I'm an engineer 
who designed for analog TV, I did so strictly in the digital domain, designing an integrated fsync, 
vsync, dot clock (and, for NTSC, color bust) sequencer in order to make Atari game systems more 
compliant with  NTSC & PAL timing standards.

> PPS:
> I know very well that even inside FFmpeg there are several
> definitions of "interlaced frames". But since we discuss filters
> in an FFmpeg filter chain, neither decoding field-encoded
> mpeg2video or paff streams nor mbaff or ildct encoding are
> relevant, only the actual content of single frames is which can
> be progressive or interlaced (for you: "not combed" or
> "combed") which is - in theory and to a very large degree in
> practice - independent of the encoding method.

Thanks for your insight on this. My experience is that regarding "decombing" frames 2 7 12 17 ..., 
'pp=linblenddeint' (whatever it is) does a better job than 'yadif'.

"lb/linblenddeint
"Linear blend deinterlacing filter that deinterlaces the given block by filtering all lines with a 
(1 2 1) filter."

I don't know what a "(1 2 1) filter" is -- I don't know to what "1 2 1" refers. pdr0 recommended it 
and I found that it works better than any of the other deinterlace filters. Without pdr0's help, I 
would never have tried it.



More information about the ffmpeg-user mailing list