[FFmpeg-devel] [PATCH] Add null video filter
Michael Niedermayer
michaelni
Sun Oct 18 23:59:09 CEST 2009
On Sun, Oct 18, 2009 at 11:21:57PM +0200, Stefano Sabatini wrote:
> On date Sunday 2009-10-18 22:34:39 +0200, Michael Niedermayer encoded:
> > On Sun, Oct 18, 2009 at 12:25:41PM +0200, Stefano Sabatini wrote:
> > > On date Thursday 2009-10-08 00:18:25 +0200, Michael Niedermayer encoded:
> [...]
> > > > probably ok if extensively tested (for example benchmarks that it does not
> > > > cause slowdown which would be an indication of extra memcpy being done
> > > > somewhere)
> > >
> > > With ffplay I didn't noticed significant slowdowns even with an insane
> > > number of null filters (256).
> > >
> > > But I noticed some slowdowns with ffmpeg, even with a relatively small
> > > number of null filters:
> > > 16: utime=4.876s
> > > 17: utime=6.368s
> > > 18: utime=9.501s
> > > 19: utime=15.745s
> > > 20: utime=28.246s
> > > 21: utime=53.067s
> > >
> > > With 32 null filters the process seems to hangs, a quick inspection
> > > with gdb revealed that the processing hangs in avfilter_poll_frame(),
> > > anyway since the problem is not related to the present filter I
> > > committed.
> >
> > please elaborate
> > what did you test, if not what was be commited?
>
> With ffplay:
> ffplay in.avi -vfilters "null,null,null,...,null"
>
> With ffmpeg:
> ffmpeg -t 5 -i in.avi -vfilters "null,null,null,...,null" -y out.avi
>
> Note that even changing the filter (e.g. using vflip) I got the same
> behavior, so I concluded that the problem was not depending on the
> null filter.
the commit of the null filter made the bug possible, so it is dependant
on it. IMHO it should not have been commited
either way a chain of null filters should not cause such exponential
slowdown, that is a very serious bug and i really think that should be
fixed before commiting more code. If not even reverting the null filter
commit.
its very important that such issues are dealt with and not just ignored
and more code commited on top of a codebase that has such issues that
have not been analyzed.
i want a stable and useable libavfilter, and i belive others want that
too ...
>
> Interrupting in gdb the second command got the debugger in the middle
> of some avfilter_poll_frame() call, (which is not used by ffplay).
>
> I'll try to inspect the problem more thoroughly, but I won't have much
> time in the next week, if someone wants to jump in and help I'll be
> grateful.
wihout looking at the code at all and not doing any tests, this smells
like some recursive calling of some code so that the calls double with
each filter
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
When you are offended at any man's fault, turn to yourself and study your
own failings. Then you will forget your anger. -- Epictetus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20091018/2e671c0e/attachment.pgp>
More information about the ffmpeg-devel
mailing list