[FFmpeg-devel] [PATCH] fix swf playback with bad audio track
Aurelien Jacobs
aurel
Sun Sep 16 23:13:22 CEST 2007
On Sun, 16 Sep 2007 20:20:05 +0200
Baptiste Coudurier <baptiste.coudurier at smartjog.com> wrote:
> Hi
>
> Michael Niedermayer wrote:
> > Hi
> >
> > On Sun, Sep 16, 2007 at 06:16:32PM +0200, Baptiste Coudurier wrote:
> > [...]
> >
> >>This is ugly indeed. Maybe we could just output the big packet with
> >>AVSTREAM_PARSE_FULL which will split out audio frames, and let the user
> >>application correctly interleave video and audio frames based on dts.
> >
> >
> > yes
> >
> >
> >
> >>Also lavf could do it in a generic way after parsing,
> >
> >
> > no
> >
> > either the file is approximately interleaved, in which case packets are
> > output as is or
> > its completely non interleaved in which case the demuxer must interleave
> > things properly by reading just what is output
>
> So, audio data must be read by a small amount at a time (would be
> audio_packet_size), and the parser should be set to AVSTREAM_PARSE_FULL
> to reconstruct frames from those small data chunks, it must not read the
> whole audio chunk which can be potentially big.
>
> Right ?
I think it's right, but the hard part IMO is to find out how much audio
and video data must be read each time in order to keep A/V sync.
IOW, find out audio packets boundaries, and how much audio samples will
be decoded out of each packet.
Aurel
More information about the ffmpeg-devel
mailing list