Lines Matching refs:gr_infos
388 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[ch].gr[gr]);
390 gr_infos->part2_3_length = getbits(mp, 12);
391 gr_infos->big_values = getbits_fast(mp, 9);
392 if (gr_infos->big_values > 288) {
393 lame_report_fnc(mp->report_err, "big_values too large! %i\n", gr_infos->big_values);
394 gr_infos->big_values = 288;
398 gr_infos->pow2gain = gainpow2 + 256 - qss + powdiff;
404 gr_infos->pow2gain += 2;
405 gr_infos->scalefac_compress = getbits_fast(mp, 4);
409 gr_infos->block_type = getbits_fast(mp, 2);
410 gr_infos->mixed_block_flag = get1bit(mp);
411 gr_infos->table_select[0] = getbits_fast(mp, 5);
412 gr_infos->table_select[1] = getbits_fast(mp, 5);
419 gr_infos->table_select[2] = 0;
422 gr_infos->full_gain[i] = gr_infos->pow2gain + sbg;
427 if (gr_infos->block_type == 0) {
433 gr_infos->region1start = 36 >> 1;
434 gr_infos->region2start = 576 >> 1;
439 gr_infos->table_select[i] = getbits_fast(mp, 5);
452 gr_infos->region1start = bandInfo[sfreq].longIdx[region0index] >> 1;
453 gr_infos->region2start = bandInfo[sfreq].longIdx[region1index] >> 1;
454 gr_infos->block_type = 0;
455 gr_infos->mixed_block_flag = 0;
457 gr_infos->preflag = get1bit(mp);
458 gr_infos->scalefac_scale = get1bit(mp);
459 gr_infos->count1table_select = get1bit(mp);
481 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[ch].gr[0]);
484 gr_infos->part2_3_length = getbits(mp, 12);
485 gr_infos->big_values = getbits_fast(mp, 9);
486 if (gr_infos->big_values > 288) {
487 lame_report_fnc(mp->report_err, "big_values too large! %i\n", gr_infos->big_values);
488 gr_infos->big_values = 288;
491 gr_infos->pow2gain = gainpow2 + 256 - qss + powdiff;
498 gr_infos->pow2gain += 2;
499 gr_infos->scalefac_compress = getbits(mp, 9);
503 gr_infos->block_type = getbits_fast(mp, 2);
504 gr_infos->mixed_block_flag = get1bit(mp);
505 gr_infos->table_select[0] = getbits_fast(mp, 5);
506 gr_infos->table_select[1] = getbits_fast(mp, 5);
511 gr_infos->table_select[2] = 0;
514 gr_infos->full_gain[i] = gr_infos->pow2gain + sbg;
520 if (gr_infos->block_type == 0) {
526 if (gr_infos->block_type == 2) {
527 if (gr_infos->mixed_block_flag == 0)
528 gr_infos->region1start = 36 >> 1;
530 gr_infos->region1start = 48 >> 1;
533 gr_infos->region1start = 54 >> 1;
535 gr_infos->region1start *= 2;
536 gr_infos->region2start = 576 >> 1;
541 gr_infos->table_select[i] = getbits_fast(mp, 5);
554 gr_infos->region1start = bandInfo[sfreq].longIdx[region0index] >> 1;
555 gr_infos->region2start = bandInfo[sfreq].longIdx[region1index] >> 1;
556 gr_infos->block_type = 0;
557 gr_infos->mixed_block_flag = 0;
559 gr_infos->scalefac_scale = get1bit(mp);
560 gr_infos->count1table_select = get1bit(mp);
569 III_get_scale_factors_1(PMPSTR mp, int *scf, struct gr_info_s *gr_infos)
576 int num0 = slen[0][gr_infos->scalefac_compress];
577 int num1 = slen[1][gr_infos->scalefac_compress];
579 if (gr_infos->block_type == 2) {
583 if (gr_infos->mixed_block_flag) {
600 int scfsi = gr_infos->scfsi;
655 III_get_scale_factors_2(PMPSTR mp, int *scf, struct gr_info_s *gr_infos, int i_stereo)
674 slen = i_slen2[gr_infos->scalefac_compress >> 1];
676 slen = n_slen2[gr_infos->scalefac_compress];
678 gr_infos->preflag = (slen >> 15) & 0x1;
681 if (gr_infos->block_type == 2) {
683 if (gr_infos->mixed_block_flag)
720 struct gr_info_s *gr_infos, int sfreq, int part2bits)
722 int shift = 1 + gr_infos->scalefac_scale;
725 int part2remain = gr_infos->part2_3_length - part2bits;
734 /* lame_report_fnc(mp->report_dbg,"part2remain = %d, gr_infos->part2_3_length = %d, part2bits = %d\n",
735 part2remain, gr_infos->part2_3_length, part2bits); */
749 int bv = gr_infos->big_values;
750 int region1 = gr_infos->region1start;
751 int region2 = gr_infos->region2start;
787 if (gr_infos->block_type == 2) {
796 if (gr_infos->mixed_block_flag) {
812 struct newhuff const *h = (struct newhuff const *) (ht + gr_infos->table_select[i]);
821 v = get_gain(gr_infos->pow2gain, (*scf++) << shift, &isbug);
825 v = get_gain(gr_infos->full_gain[lwin], (*scf++) << shift, &isbug);
892 struct newhuff const *h = (struct newhuff const *) (htc + gr_infos->count1table_select);
914 v = get_gain(gr_infos->pow2gain, (*scf++) << shift, &isbug);
918 v = get_gain(gr_infos->full_gain[lwin], (*scf++) << shift, &isbug);
974 gr_infos->maxband[0] = max[0] + 1;
975 gr_infos->maxband[1] = max[1] + 1;
976 gr_infos->maxband[2] = max[2] + 1;
977 gr_infos->maxbandl = max[3] + 1;
982 gr_infos->maxb = rmax ? shortLimit[sfreq][rmax] : longLimit[sfreq][max[3] + 1];
990 int const *pretab = (int const *) (gr_infos->preflag ? pretab1 : pretab2);
1002 struct newhuff const *h = (struct newhuff const *) (ht + gr_infos->table_select[i]);
1009 v = get_gain(gr_infos->pow2gain, ((*scf++) + (*pretab++)) << shift, &isbug);
1078 struct newhuff const *h = (struct newhuff const *) (htc + gr_infos->count1table_select);
1097 v = get_gain(gr_infos->pow2gain, ((*scf++) + (*pretab++)) << shift, &isbug);
1129 gr_infos->maxbandl = max + 1;
1130 gr_infos->maxb = longLimit[sfreq][gr_infos->maxbandl];
1145 ,gr_infos->big_values
1146 ,gr_infos->region1start
1147 ,gr_infos->region2start
1148 ,gr_infos->block_type
1149 ,gr_infos->mixed_block_flag
1165 ,gr_infos->block_type
1166 ,gr_infos->mixed_block_flag
1197 struct gr_info_s *gr_infos, int sfreq, int ms_stereo, int lsf)
1204 int p = gr_infos->scalefac_compress & 0x1;
1225 if (gr_infos->block_type == 2) {
1227 if (gr_infos->mixed_block_flag)
1232 int is_p, sb, idx, sfb = gr_infos->maxband[lwin]; /* sfb is minimal 3 for mixed mode */
1237 is_p = scalefac[sfb * 3 + lwin - gr_infos->mixed_block_flag]; /* scale: 0-15 */
1256 is_p = scalefac[11 * 3 + lwin - gr_infos->mixed_block_flag]; /* scale: 0-15 */
1260 is_p = scalefac[10 * 3 + lwin - gr_infos->mixed_block_flag]; /* scale: 0-15 */
1281 int sfb = gr_infos->maxbandl;
1303 else { /* ((gr_infos->block_type != 2)) */
1305 int sfb = gr_infos->maxbandl;
1342 III_antialias(real xr[SBLIMIT][SSLIMIT], struct gr_info_s *gr_infos)
1346 if (gr_infos->block_type == 2) {
1347 if (!gr_infos->mixed_block_flag)
1352 sblim = gr_infos->maxb - 1;
1639 int ch, struct gr_info_s *gr_infos)
1657 if (gr_infos->mixed_block_flag) {
1666 bt = gr_infos->block_type;
1668 for (; sb < (int) gr_infos->maxb; sb += 2, tspnt += 2, rawout1 += 36, rawout2 += 36) {
1674 for (; sb < (int) gr_infos->maxb; sb += 2, tspnt += 2, rawout1 += 36, rawout2 += 36) {
1745 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[ch].gr[gr]);
1746 databits += gr_infos->part2_3_length;
1801 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[0].gr[gr]);
1805 part2bits = III_get_scale_factors_2(mp, scalefacs[0], gr_infos, 0);
1807 part2bits = III_get_scale_factors_1(mp, scalefacs[0], gr_infos);
1816 /* lame_report_fnc(mp->report_err, "calling III dequantize sample 1 gr_infos->part2_3_length %d\n", gr_infos->part2_3_length); */
1817 if (III_dequantize_sample(mp, hybridIn[0], scalefacs[0], gr_infos, sfreq, part2bits))
1821 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[1].gr[gr]);
1824 part2bits = III_get_scale_factors_2(mp, scalefacs[1], gr_infos, i_stereo);
1826 part2bits = III_get_scale_factors_1(mp, scalefacs[1], gr_infos);
1835 /* lame_report_fnc(mp->report_err, "calling III dequantize sample 2 gr_infos->part2_3_length %d\n", gr_infos->part2_3_length); */
1836 if (III_dequantize_sample(mp, hybridIn[1], scalefacs[1], gr_infos, sfreq, part2bits))
1851 III_i_stereo(hybridIn, scalefacs[1], gr_infos, sfreq, ms_stereo, fr->lsf);
1854 if (gr_infos->maxb > mp->sideinfo.ch[0].gr[gr].maxb)
1855 mp->sideinfo.ch[0].gr[gr].maxb = gr_infos->maxb;
1857 gr_infos->maxb = mp->sideinfo.ch[0].gr[gr].maxb;
1865 for (i = 0; i < (int) (SSLIMIT * gr_infos->maxb); i++, in0++)
1873 for (i = 0; i < (int) (SSLIMIT * gr_infos->maxb); i++)
1896 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[ch].gr[gr]);
1897 mp->pinfo->big_values[gr][ch] = gr_infos->big_values;
1898 mp->pinfo->scalefac_scale[gr][ch] = gr_infos->scalefac_scale;
1899 mp->pinfo->mixed[gr][ch] = gr_infos->mixed_block_flag;
1900 mp->pinfo->mpg123blocktype[gr][ch] = gr_infos->block_type;
1901 mp->pinfo->mainbits[gr][ch] = gr_infos->part2_3_length;
1902 mp->pinfo->preflag[gr][ch] = gr_infos->preflag;
1904 mp->pinfo->scfsi[ch] = gr_infos->scfsi;
1909 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[ch].gr[gr]);
1911 if (2 == gr_infos->block_type) {
1916 is_p = scalefac[sfb*3+lwin-gr_infos->mixed_block_flag];
1920 -ifqstep * mp->pinfo->sfb_s[gr][ch][j - gr_infos->mixed_block_flag];
1931 if (gr_infos->preflag)
1951 struct gr_info_s *gr_infos = &(mp->sideinfo.ch[ch].gr[gr]);
1952 III_antialias(hybridIn[ch], gr_infos);
1953 III_hybrid(mp, hybridIn[ch], hybridOut[ch], ch, gr_infos);