Lines Matching defs:gbc
259 GetBitContext *gbc = &s->gbc;
265 s->dialog_normalization[(!s->channel_mode)-i] = -get_bits(gbc, 5);
274 if (s->compression_exists[(!s->channel_mode)-i] = get_bits1(gbc)) {
276 AC3_HEAVY_RANGE(get_bits(gbc, 8));
278 if (get_bits1(gbc))
279 skip_bits(gbc, 8); //skip language code
280 if (get_bits1(gbc))
281 skip_bits(gbc, 7); //skip audio production information
284 skip_bits(gbc, 2); //skip copyright bit and original bitstream bit
288 if (get_bits1(gbc))
289 skip_bits(gbc, 14); //skip timecode1
290 if (get_bits1(gbc))
291 skip_bits(gbc, 14); //skip timecode2
293 if (get_bits1(gbc)) {
294 s->preferred_downmix = get_bits(gbc, 2);
295 s->center_mix_level_ltrt = get_bits(gbc, 3);
296 s->surround_mix_level_ltrt = av_clip(get_bits(gbc, 3), 3, 7);
297 s->center_mix_level = get_bits(gbc, 3);
298 s->surround_mix_level = av_clip(get_bits(gbc, 3), 3, 7);
300 if (get_bits1(gbc)) {
301 s->dolby_surround_ex_mode = get_bits(gbc, 2);
302 s->dolby_headphone_mode = get_bits(gbc, 2);
303 skip_bits(gbc, 10); // skip adconvtyp (1), xbsi2 (8), encinfo (1)
308 if (get_bits1(gbc)) {
309 i = get_bits(gbc, 6);
311 skip_bits(gbc, 8);
326 err = ff_ac3_parse_header(&s->gbc, &hdr);
452 GetBitContext *gbc, int exp_strategy, int ngrps,
462 expacc = get_bits(gbc, 7);
544 GetBitContext *gbc = &s->gbc;
563 int bits = get_bits(gbc, 5);
575 int bits = get_bits(gbc, 7);
583 mantissa = b3_mantissas[get_bits(gbc, 3)];
590 int bits = get_bits(gbc, 7);
597 mantissa = b5_mantissas[get_bits(gbc, 4)];
605 mantissa = (unsigned)get_sbits(gbc, quantization_tab[bap]) << (24 - quantization_tab[bap]);
779 * @param[in] gbc bit reader context
790 static void decode_band_structure(GetBitContext *gbc, int blk, int eac3,
809 if (!eac3 || get_bits1(gbc)) {
811 band_struct[subbnd] = get_bits1(gbc);
841 GetBitContext *bc = &s->gbc;
898 GetBitContext *bc = &s->gbc;
977 GetBitContext *bc = &s->gbc;
1046 GetBitContext *bc = &s->gbc;
1098 GetBitContext *gbc = &s->gbc;
1105 s->block_switch[ch] = get_bits1(gbc);
1114 s->dither_flag[ch] = get_bits1(gbc);
1121 if (get_bits1(gbc)) {
1124 int range_bits = get_bits(gbc, 8);
1136 if (s->eac3 && (!blk || get_bits1(gbc))) {
1137 s->spx_in_use = get_bits1(gbc);
1156 if (s->eac3 ? s->cpl_strategy_exists[blk] : get_bits1(gbc)) {
1178 if ((s->eac3 && !blk) || get_bits1(gbc)) {
1186 s->rematrixing_flags[bnd] = get_bits1(gbc);
1197 s->exp_strategy[blk][ch] = get_bits(gbc, 2 - (ch == s->lfe_ch));
1213 int bandwidth_code = get_bits(gbc, 6);
1234 s->dexps[ch][0] = get_bits(gbc, 4) << !ch;
1235 if (decode_exponents(s, gbc, s->exp_strategy[blk][ch],
1241 skip_bits(gbc, 2); /* skip gainrng */
1247 if (get_bits1(gbc)) {
1248 s->bit_alloc_params.slow_decay = ff_ac3_slow_decay_tab[get_bits(gbc, 2)] >> s->bit_alloc_params.sr_shift;
1249 s->bit_alloc_params.fast_decay = ff_ac3_fast_decay_tab[get_bits(gbc, 2)] >> s->bit_alloc_params.sr_shift;
1250 s->bit_alloc_params.slow_gain = ff_ac3_slow_gain_tab[get_bits(gbc, 2)];
1251 s->bit_alloc_params.db_per_bit = ff_ac3_db_per_bit_tab[get_bits(gbc, 2)];
1252 s->bit_alloc_params.floor = ff_ac3_floor_tab[get_bits(gbc, 3)];
1264 if (s->snr_offset_strategy && get_bits1(gbc)) {
1267 csnr = (get_bits(gbc, 6) - 15) << 4;
1271 snr = (csnr + get_bits(gbc, 4)) << 2;
1281 s->fast_gain[ch] = ff_ac3_fast_gain_tab[get_bits(gbc, 3)];
1294 if (s->fast_gain_syntax && get_bits1(gbc)) {
1297 s->fast_gain[ch] = ff_ac3_fast_gain_tab[get_bits(gbc, 3)];
1308 if (s->frame_type == EAC3_FRAME_TYPE_INDEPENDENT && get_bits1(gbc)) {
1309 skip_bits(gbc, 10); // skip converter snr offset
1314 if (s->first_cpl_leak || get_bits1(gbc)) {
1315 int fl = get_bits(gbc, 3);
1316 int sl = get_bits(gbc, 3);
1334 if (s->dba_syntax && get_bits1(gbc)) {
1337 s->dba_mode[ch] = get_bits(gbc, 2);
1347 s->dba_nsegs[ch] = get_bits(gbc, 3) + 1;
1349 s->dba_offsets[ch][seg] = get_bits(gbc, 5);
1350 s->dba_lengths[ch][seg] = get_bits(gbc, 4);
1351 s->dba_values[ch][seg] = get_bits(gbc, 3);
1397 if (s->skip_syntax && get_bits1(gbc)) {
1398 int skipl = get_bits(gbc, 9);
1399 skip_bits_long(gbc, 8 * skipl);
1540 if ((ret = init_get_bits8(&s->gbc, buf, buf_size)) < 0)
1689 if ((ret = init_get_bits8(&s->gbc, buf + s->frame_size, buf_size - s->frame_size)) < 0)
1692 err = ff_ac3_parse_header(&s->gbc, &hdr);