mantissa = b5_mantissas[get_bits(gbc, 4)];
break;
default: /* 6 to 15 */
- mantissa = get_bits(gbc, quantization_tab[bap]);
/* Shift mantissa and sign-extend it. */
- mantissa = (mantissa << (32-quantization_tab[bap]))>>8;
+ mantissa = get_sbits(gbc, quantization_tab[bap]);
+ mantissa <<= 24 - quantization_tab[bap];
break;
}
coeffs[freq] = mantissa >> exps[freq];
};
static const AVClass ac3_decoder_class = {
- .class_name = "(E-)AC3 decoder",
+ .class_name = "AC3 decoder",
.item_name = av_default_item_name,
.option = options,
.version = LIBAVUTIL_VERSION_INT,
};
#if CONFIG_EAC3_DECODER
+static const AVClass eac3_decoder_class = {
+ .class_name = "E-AC3 decoder",
+ .item_name = av_default_item_name,
+ .option = options,
+ .version = LIBAVUTIL_VERSION_INT,
+};
AVCodec ff_eac3_decoder = {
.name = "eac3",
.type = AVMEDIA_TYPE_AUDIO,
.sample_fmts = (const enum AVSampleFormat[]) {
AV_SAMPLE_FMT_FLT, AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE
},
- .priv_class = &ac3_decoder_class,
+ .priv_class = &eac3_decoder_class,
};
#endif