[FFmpeg-devel] [PATCH] fix swf playback with bad audio track

Michael Niedermayer michaelni
Sun Sep 16 19:16:47 CEST 2007


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.


> Also lavf could do it in a generic way after parsing, 


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

letting lavf do the interleaving of a non interleaved file means reading
the whole first stream (possibly several gb) into memory that just doesnt

also dont forget av sync must be done by the application, the audio hw
as well as video output do generally have some delay, so doing the
interleaving generically in lavf for nearly correctly interleaved files
does nothing but slowing things down the app still has to do the whole
again to compensate for audio out delay and such. and doing it for really
non interleaved containers where the demuxer blindly outputs all packets
from one stream and then from the next just doesnt work

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Many that live deserve death. And some that die deserve life. Can you give
it to them? Then do not be too eager to deal out death in judgement. For
even the very wise cannot see all ends. -- Gandalf
-------------- 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/20070916/36957ed3/attachment.pgp>

More information about the ffmpeg-devel mailing list