[FFmpeg-devel] [PATCH v2 4/8] ffmpeg: remove sub-frame warning
nfxjfg at googlemail.com
Wed Mar 23 20:44:41 CET 2016
On Wed, 23 Mar 2016 18:37:25 +0100
Michael Niedermayer <michael at niedermayer.cc> wrote:
> On Wed, Mar 23, 2016 at 06:06:37PM +0100, wm4 wrote:
> > On Wed, 23 Mar 2016 17:51:11 +0100
> > Michael Niedermayer <michael at niedermayer.cc> wrote:
> > > On Wed, Mar 23, 2016 at 02:02:11PM +0100, wm4 wrote:
> > > > It's not practical to keep this with the new decode API.
> > > > ---
> > > > ffmpeg.c | 7 -------
> > > > ffmpeg.h | 1 -
> > > > 2 files changed, 8 deletions(-)
> > >
> > > its not practical in ffmpeg.c but libavcodec should be able to easily
> > > check that a decoder which doesnt declare AV_CODEC_CAP_SUBFRAMES
> > > doesnt decode "subframes"
> > > Can you move this check into libavcodec ?
> > > i think otherwise nothing would be checking for missing
> > > AV_CODEC_CAP_SUBFRAMES anymore
> > >
> > What's the point of this check?
> to keep track of / detect the cases that put multiple decodable frames
> in a packet.
> Whats the point of that?
> there where several IIRC
> one is that when too many frames are put in a packet
> latency increases, another is that seeking granularity is worse
> (if its not even one packet for the whole file ...)
It's true that too many frames in a packet isn't ideal, but that's not
what the code checks.
It checks if an audio decoder not marked with AV_CODEC_CAP_SUBFRAMES
consumes partial packets. That might be useful as debug check in
libavcodec or so, or by properly reviewing patches for new decoders.
> also when stream copying most muxers do expect 1 frame per packet
> so that would generate invalid files
> AV_CODEC_CAP_SUBFRAMES kind of says, "i know it has multiple frames
> per packet and thats ok or its just nt practical to do anything about"
More information about the ffmpeg-devel