00001 /* 00002 * Layer 3 side include file 00003 * 00004 * Copyright (c) 1999 Mark Taylor 00005 * 00006 * This library is free software; you can redistribute it and/or 00007 * modify it under the terms of the GNU Lesser General Public 00008 * License as published by the Free Software Foundation; either 00009 * version 2 of the License, or (at your option) any later version. 00010 * 00011 * This library is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00014 * Library General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU Lesser General Public 00017 * License along with this library; if not, write to the 00018 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00019 * Boston, MA 02111-1307, USA. 00020 */ 00021 00022 #ifndef LAME_L3SIDE_H 00023 #define LAME_L3SIDE_H 00024 00025 /* max scalefactor band, max(SBMAX_l, SBMAX_s*3, (SBMAX_s-3)*3+8) */ 00026 #define SFBMAX (SBMAX_s*3) 00027 00028 /* Layer III side information. */ 00029 typedef struct { 00030 int l[1 + SBMAX_l]; 00031 int s[1 + SBMAX_s]; 00032 int psfb21[1 + PSFB21]; 00033 int psfb12[1 + PSFB12]; 00034 } scalefac_struct; 00035 00036 00037 typedef struct { 00038 FLOAT l[SBMAX_l]; 00039 FLOAT s[SBMAX_s][3]; 00040 } III_psy_xmin; 00041 00042 typedef struct { 00043 III_psy_xmin thm; 00044 III_psy_xmin en; 00045 } III_psy_ratio; 00046 00047 typedef struct { 00048 FLOAT xr[576]; 00049 int l3_enc[576]; 00050 int scalefac[SFBMAX]; 00051 FLOAT xrpow_max; 00052 00053 int part2_3_length; 00054 int big_values; 00055 int count1; 00056 int global_gain; 00057 int scalefac_compress; 00058 int block_type; 00059 int mixed_block_flag; 00060 int table_select[3]; 00061 int subblock_gain[3 + 1]; 00062 int region0_count; 00063 int region1_count; 00064 int preflag; 00065 int scalefac_scale; 00066 int count1table_select; 00067 00068 int part2_length; 00069 int sfb_lmax; 00070 int sfb_smin; 00071 int psy_lmax; 00072 int sfbmax; 00073 int psymax; 00074 int sfbdivide; 00075 int width[SFBMAX]; 00076 int window[SFBMAX]; 00077 int count1bits; 00078 /* added for LSF */ 00079 const int *sfb_partition_table; 00080 int slen[4]; 00081 00082 int max_nonzero_coeff; 00083 } gr_info; 00084 00085 typedef struct { 00086 gr_info tt[2][2]; 00087 int main_data_begin; 00088 int private_bits; 00089 int resvDrain_pre; 00090 int resvDrain_post; 00091 int scfsi[2][4]; 00092 } III_side_info_t; 00093 00094 #endif