[FFmpeg-devel] [PATCH] libavfilter-soc: Make overlay handle still images
Fri May 8 11:58:16 CEST 2009
On Fri, 8 May 2009, Vitor Sessak wrote:
> > Actually, there's a use for them. Imagine that there's a frame available in
> > input 0, but none at all in input 1.
> Is there any way the if (!over->pics || !over->pics) can be
> triggered other than in the first time request_frame() is called? If no,
> "!over->pics" and "!over->pics" are always true.
> Note that if one of the inputs each EOF, it will stay at EOF. Note also
> that the poll_frame mechanism guarantees that there is either an
> available frame or EOF for each input.
I guess that's true in principle, but what if request_frame() still is
called (for some unknown reason, haven't checked through the rest of the
framework to see if there's something stopping this from happening) after
the first call which returned EOF?
I'd say this is a small cost for extra robustness in the individual filter
(if the checks are removed and request_frame() is called multiple times,
it would start leaking memory and invalidating assertions in start_frame()
and whatnot), but if you still think it is unnecessary, I'll remove it.
More information about the ffmpeg-devel