[FFmpeg-devel] [PATCH] avfilter: Port mp=softpulldown to lavfi

Michael Niedermayer michaelni at gmx.at
Thu Jan 29 19:04:28 CET 2015


On Thu, Jan 29, 2015 at 05:42:39PM +0000, Paul B Mahol wrote:
> On 1/29/15, Michael Niedermayer <michaelni at gmx.at> wrote:
> > On Thu, Jan 29, 2015 at 09:20:43AM +0000, Paul B Mahol wrote:
> >> On 1/29/15, Michael Niedermayer <michaelni at gmx.at> wrote:
> >> > On Wed, Jan 28, 2015 at 03:13:27PM +0000, Paul B Mahol wrote:
> >> >> Signed-off-by: Paul B Mahol <onemda at gmail.com>
> >> >> ---
> >> >> Bit-exact with mp=softpulldown except first frame which is
> >> >> uninitialized
> >> >> data in mp filter.
> >> >
> >> >> TODO: pts needs update, workaround is to use setpts filter.
> >> >
> >> > patch LGTM except the pts / time_base issue
> >>
> >> mp=softpulldown sets all frames to MP_NOPTS_VALUE.
> >>
> >> I do not see way how to set filter to use variable frame rate, which
> >> is possible as repeat_pict can change during stream.
> >
> > Heres my attempt to fix the issue
> > The problem which i saw was that the first frames timestamp was
> > stored in the temporary internal frame and then returned for many
> > frames so they all had a incorrect and equal to the video starttime
> > value
> >
> > Below this timestamp is reset to AV_NOPTS_VALUE and
> > the code below takes the somewhat conservative approuch of only
> > adjusting timestamps for the common 30000/1001 case and otherwise
> > only passing untouched timestamps through or if they are off by a
> > field period seting them to AV_NOPTS_VALUE if fps != 30000/1001
> >
> > timebases and frame rates are identical between input and output
> > they needed no adjustment for the testcase i could find
> 
> What testcase?

interlaced_flag_switch.mpeg though this one contains some damaged
frames so maybe its not the ideal testcase
was just the first i found


> The pattern can change to almost anything.

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Old school: Use the lowest level language in which you can solve the problem
            conveniently.
New school: Use the highest level language in which the latest supercomputer
            can solve the problem without the user falling asleep waiting.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150129/a65e6b86/attachment.asc>


More information about the ffmpeg-devel mailing list