[FFmpeg-devel] yadif: Don't process progressive frames and select proper pix format
ronag89 at gmail.com
Sat May 5 18:17:52 CEST 2012
> Le septidi 17 floréal, an CCXX, Robert Nagy a écrit :
> > 1. It will auto-insert a scale filter to ensure format compatibility with
> > yadif, even if fed with a progressive stream with auto_enable==true, e.g.
> > progressive bgra stream will be converted to yuv420, for no reason.
> Is there a fundamental reason that would make yadif impossible to port to
> RGB formats? If not, that would be a much better solution IMHO. Ans since
> yadif already supports YUV444P, i.e. a 3-components format with no
> subsampling, it should only be a matter of handling packed formats.
I agree, however when I asked about that the reply I got was that yadif
somehow assumed YUV in the algorithm. Don't know the details.
> 2. Incorrect auto-insert scale filters, e.g. bgra -> yadif, will become,
> > bgra -> yuv420 -> yadif, instead of more appropriate bgra -> yuva420 ->
> > yadif.
> This is not yadif-specific: automatic conversions should try to choose a
> more conservative format. I thought it was already done.
Doesn't seem to be the case.
> > The attached patch tries to address these issues by moving format
> > into the yadif filter. However, the problem with this hack solution is
> > one need to add an explicit scale filter after any yadif filter in order
> > not confuse the filter graph about formats.'
> I am not really happy about that solution: that makes a lot of duplicated
> code, and furthermore it makes an additional case where automatic
> happens, and this is not good when people want to control conversion
I agree. The best solution would be to add rgb support to the filter.
More information about the ffmpeg-devel