[Ffmpeg-devel] [PATCH] getting basic parameters when demuxing AC3

Michael Niedermayer michaelni
Sat May 28 23:10:15 CEST 2005


Hi

On Saturday 28 May 2005 22:01, Nico Sabbi wrote:
> Michael Niedermayer wrote:
> >Hi
> >
> >On Saturday 28 May 2005 11:32, Nico Sabbi wrote:
> >>Hi,
> >>this patch assigns bitrate, sample-rate and number of channels when
> >>demuxing ac3 in raw mode.
> >>Successfully tested with mencoder -demuxer 35, that otherwise fails.
> >
> >rejected, libavformat has a ac3 parser which does that already cleanly,
> > its just disabled in mencoder IIRC, to fix this you just have to make the
> > ac3 parser in (parser.c) independant from libavcdoec/liba52
> >
> >[...]
>
> I hope it's correct now.
> I didn't copy a52_syncinfo() because it can't be used in an lgpl  env,
> and forcing
> the gpl for such a small piece of code is nonsense imo, so I
> reimplemented it.
> Where should I set the bits_per_sample and the block_size fields? in
> ac3_parse() ?

ac3_parse seems to be the correct place but what you did set them to in your 
initial patch does not seem correct to me

mdct based audio codecs like ac3, mp3, vorbis, ... dont really have a 
bits_per_sample value do they?

and block_align (theres no block_size) is the packet size in bytes if it is 
constant, somehow i dont think its 8 for AC3

-- 
Michael





More information about the ffmpeg-devel mailing list