[Ffmpeg-devel] [PATCH] DVR-MS probe audio format - was DVR-MS bug (MP2 decoding)

Michael Niedermayer michaelni
Sat Mar 31 01:42:31 CEST 2007


Hi

On Fri, Mar 30, 2007 at 02:02:07PM -0500, John Donaghy wrote:
> >
> >hmm seems this is a missunderstanding, ive no problem with setting
> >codec_id
> >to CODEC_ID_NONE
> >what i was complaining about was setting codec_tag to 0 which is wrong as
> >that might not be the codec_tag stored in the asf file ...
> 
> 
> I'd already removed the code that was setting the codec_tag (and the
> frame_size) but it makes no difference either way. The proposed patch works
> for ac3 audio streams ok but for mp2 audio I get the output below and then
> ffmpeg crashes.

crash -> gdb output

> 
> I think it is being caused by the fact that the initial audio frame reads
> dont read complete mp2 frames because they dont know what the audio codec is
> at that point. I could be wrong though and I dont know why this doesnt
> present a problem to the ac3 decoder.

hmm uhm, i hate dvr-ms

try av_read_frame_flush() after the codec is detected
and try av_seek_frame() to get back to the start
this is of course dirty and iam not happy about it but i dont see an easy
alternative, that is if this fixes it at all ...

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

I have never wished to cater to the crowd; for what I know they do not
approve, and what they approve I do not know. -- Epicurus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070331/7fa70e4e/attachment.pgp>



More information about the ffmpeg-devel mailing list