[Ffmpeg-cvslog] r5663 - in trunk: libavcodec/utils.c libavformat/voc.c

Aurelien Jacobs aurel
Sat Jul 8 01:01:44 CEST 2006


On Sat, 8 Jul 2006 00:42:41 +0200
Michael Niedermayer <michaelni at gmx.at> wrote:

> Hi
> 
> On Sat, Jul 08, 2006 at 12:42:36AM +0200, aurel wrote:
> [...]
> > +    case CODEC_ID_ADPCM_CT:
> > +    case CODEC_ID_ADPCM_SBPRO_2:
> > +    case CODEC_ID_ADPCM_SBPRO_3:
> > +    case CODEC_ID_ADPCM_SBPRO_4:
> > +        return 0;
> [...]
> > -    case CODEC_ID_ADPCM_CT:
> > -        return 4;
> [...]
> > -            dec->bits_per_sample = voc_get_bps(dec->codec_id);
> > +            dec->bits_per_sample = av_get_bits_per_sample(dec->codec_id);
> 
> interresting change ...

Well, setting bits_per_sample to anything >0 and <8 generate a divide by zero
in libavformat/utils.c:get_audio_frame_size(). This functions seems to
imply that ADPCM codecs should set bits_per_sample to 0.
About ADPCM_CT, the original value of 4 was certainly wrong but I never
found a voc sample using this codec.

Aurel




More information about the ffmpeg-cvslog mailing list