[FFmpeg-user] Is FFV1 able to encode interlaced video?

Carl Eugen Hoyos cehoyos at ag.or.at
Mon Aug 10 20:11:58 CEST 2015


MrNice <wxcvbn2006 <at> iol.ie> writes:

> ./ffmpeg -debug 1 -f pulse -ar 44100 -ac 2 -channel_layout stereo
> -thread_queue_size 512 -i alsa_input.pci-0000_00_14.2.analog-stereo -f
> v4l2 -ts mono2abs -channel 1 -video_size 720x576 -pix_fmt yuyv422
> -thread_queue_size 512 -i /dev/video0 -c:v ffv1 -level 3 -aspect 4:3
> -pix_fmt yuv422p -c:a pcm_s16le /Store3/Test/t_`date +%Y%m%d_%H%M`.mkv
> -aspect 4:3 -f sdl "Dazzle output"
> 
> So, AFAIK, the input to ffmpeg is interlaced.

No.

What I mean is: This command cannot tell you 
if the input is interlaced or not, you can 
only look at the actual content as shown by 
sdl to find out or use the idet filter.

> - All the readings I did say interlaced 
> input should be kept interlaced.

And I tried to explain that ffv1 - because 
it is a lossless codec - cannot make the 
interlacing go away.

But what is actually meant with above is:
If you use a lossy codec (and you are interested 
in high quality with low bitrate) then you have 
to tell your encoder that the input is interlaced 
if it is because quality will suffer a lot.
If you tell your encoder that your progressive 
content is interlaced, quality will only suffer a 
little, this is why TV stations always encode as 
interlaced (here).

[...]

> - With mediainfo, a file encoded with x264 is 
> noted as progressive or interlaced, whereas FFV1 
> as no information.

mediainfo cannot tell you if your video is 
interlaced or not. It can tell you if the encoder 
was called with the option "interlaced encoding".

> - I tried to play FFV1 files and look the image 
> to guess with VLC (de-interlace disabled) and it 
> looks progressive. Seems to be odds with your 
> answer.

Did you also look at the input?

> - In your answer, do you mean that if I take the 
> FFV1 file in a video editor then render encoded 
> with a encoder that can handle interlaced video 
> (x264), I will get interlaced?

(I may misunderstand this question.)
It is possible to interlace progressive video and 
it is possible to de-interlace interlaced video.
In both cases, quality will generally suffer.

> - Is it better to encode the capture in x264 
> instead FFV1?

Only you can answer.
(But the answer should not be: I use x264 for 
lossless encoding because it is standardized.)

> I saw a big difference in the CPU usage it's 
> what I stay so far with FFV1.

Sounds like one possible criterion.

> - I can read in the output:
> The V4L2 driver is using the interlaced mode

This may mean that the content actually is 
interlaced, I don't know.

> For my information what does mean this 
> (interl:0) in the output?:
> w:iw h:ih flags:'0x4' interl:0

If you use w == iw and h == ih I don't think it 
matters.

Carl Eugen



More information about the ffmpeg-user mailing list