| 1 | /* |
| 2 | * lame utility library include file |
| 3 | * |
| 4 | * Copyright (c) 1999 Albert L Faber |
| 5 | * Copyright (c) 2008 Robert Hegemann |
| 6 | * |
| 7 | * This library is free software; you can redistribute it and/or |
| 8 | * modify it under the terms of the GNU Library General Public |
| 9 | * License as published by the Free Software Foundation; either |
| 10 | * version 2 of the License, or (at your option) any later version. |
| 11 | * |
| 12 | * This library is distributed in the hope that it will be useful, |
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 15 | * Library General Public License for more details. |
| 16 | * |
| 17 | * You should have received a copy of the GNU Library General Public |
| 18 | * License along with this library; if not, write to the |
| 19 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
| 20 | * Boston, MA 02111-1307, USA. |
| 21 | */ |
| 22 | |
| 23 | #ifndef LAME_UTIL_H |
| 24 | #define LAME_UTIL_Hcxx . . $ `external/lame/util.h:24:9`! |
| 25 | |
| 26 | #include "l3side.h"cxx . . $ `<file>/external/lame/l3side.h`/ |
| 27 | #include "id3tag.h"cxx . . $ `<file>/external/lame/id3tag.h`/ |
| 28 | #include "lame_global_flags.h"cxx . . $ `<file>/external/lame/lame_global_flags.h`/ |
| 29 | |
| 30 | #ifdef __cplusplus |
| 31 | extern "C" { |
| 32 | #endif |
| 33 | |
| 34 | /*********************************************************************** |
| 35 | * |
| 36 | * Global Definitions |
| 37 | * |
| 38 | ***********************************************************************/ |
| 39 | |
| 40 | #ifndef FALSE |
| 41 | #define FALSEcxx . . $ `external/lame/util.h:41:17`! 0 |
| 42 | #endif |
| 43 | |
| 44 | #ifndef TRUE |
| 45 | #define TRUEcxx . . $ `external/lame/util.h:45:17`! (!FALSE) |
| 46 | #endif |
| 47 | |
| 48 | #ifdef UINT_MAXcxx . . $ `<external>/67164224788392828/limits.h:124:9`! |
| 49 | # define MAX_U_32_NUMcxx . . $ `external/lame/util.h:49:18`! UINT_MAXcxx . . $ `<external>/67164224788392828/limits.h:124:9`! |
| 50 | #else |
| 51 | # define MAX_U_32_NUM 0xFFFFFFFF |
| 52 | #endif |
| 53 | |
| 54 | #ifndef PI |
| 55 | # ifdef M_PIcxx . . $ `<external>/11263917310783833665/math.h:1121:10`! |
| 56 | # define PIcxx . . $ `external/lame/util.h:56:17`! M_PI |
| 57 | # else |
| 58 | # define PI 3.14159265358979323846 |
| 59 | # endif |
| 60 | #endif |
| 61 | |
| 62 | |
| 63 | #ifdef M_LN2cxx . . $ `<external>/11263917310783833665/math.h:1119:10`! |
| 64 | # define LOG2cxx . . $ `external/lame/util.h:64:17`! M_LN2 |
| 65 | #else |
| 66 | # define LOG2 0.69314718055994530942 |
| 67 | #endif |
| 68 | |
| 69 | #ifdef M_LN10cxx . . $ `<external>/11263917310783833665/math.h:1120:10`! |
| 70 | # define LOG10cxx . . $ `external/lame/util.h:70:17`! M_LN10 |
| 71 | #else |
| 72 | # define LOG10 2.30258509299404568402 |
| 73 | #endif |
| 74 | |
| 75 | |
| 76 | #ifdef M_SQRT2cxx . . $ `<external>/11263917310783833665/math.h:1127:10`! |
| 77 | # define SQRT2cxx . . $ `external/lame/util.h:77:17`! M_SQRT2 |
| 78 | #else |
| 79 | # define SQRT2 1.41421356237309504880 |
| 80 | #endif |
| 81 | |
| 82 | |
| 83 | #define CRC16_POLYNOMIALcxx . . $ `external/lame/util.h:83:17`! 0x8005 |
| 84 | |
| 85 | #define MAX_BITS_PER_CHANNELcxx . . $ `external/lame/util.h:85:9`! 4095 |
| 86 | #define MAX_BITS_PER_GRANULEcxx . . $ `external/lame/util.h:86:9`! 7680 |
| 87 | |
| 88 | /* "bit_stream.h" Definitions */ |
| 89 | #define BUFFER_SIZEcxx . . $ `external/lame/util.h:89:17`! LAME_MAXMP3BUFFERcxx . . $ `external/lame/lame.h:1322:9`! |
| 90 | |
| 91 | #define Mincxx . . $ `external/lame/util.h:91:17`!(A, B) ((A) < (B) ? (A) : (B)) |
| 92 | #define Maxcxx . . $ `external/lame/util.h:92:17`!(A, B) ((A) > (B) ? (A) : (B)) |
| 93 | |
| 94 | /* log/log10 approximations */ |
| 95 | #ifdef USE_FAST_LOGcxx . . $ `external/lame/lame__config.h:292:9`! |
| 96 | #define FAST_LOG10cxx . . $ `external/lame/util.h:96:17`!(x) (fast_log2(x)*(LOG2/LOG10)) |
| 97 | #define FAST_LOGcxx . . $ `external/lame/util.h:97:17`!(x) (fast_log2(x)*LOG2) |
| 98 | #define FAST_LOG10_Xcxx . . $ `external/lame/util.h:98:17`!(x,y) (fast_log2(x)*(LOG2/LOG10*(y))) |
| 99 | #define FAST_LOG_Xcxx . . $ `external/lame/util.h:99:17`!(x,y) (fast_log2(x)*(LOG2*(y))) |
| 100 | #else |
| 101 | #define FAST_LOG10(x) log10(x) |
| 102 | #define FAST_LOG(x) log(x) |
| 103 | #define FAST_LOG10_X(x,y) (log10(x)*(y)) |
| 104 | #define FAST_LOG_X(x,y) (log(x)*(y)) |
| 105 | #endif |
| 106 | |
| 107 | |
| 108 | struct replaygain_datacxx . . $ replaygain_data#; |
| 109 | #ifndef replaygain_data_defined |
| 110 | #define replaygain_data_definedcxx . . $ `external/lame/util.h:110:9`! |
| 111 | typedef struct replaygain_datacxx . . $ replaygain_data# replaygain_tcxx . . $ replaygain_t#; |
| 112 | #endif |
| 113 | struct plotting_datacxx . . $ plotting_data#; |
| 114 | #ifndef plotting_data_defined |
| 115 | #define plotting_data_definedcxx . . $ `external/lame/util.h:115:9`! |
| 116 | typedef struct plotting_datacxx . . $ plotting_data# plotting_datacxx . . $ plotting_data#; |
| 117 | #endif |
| 118 | |
| 119 | /*********************************************************************** |
| 120 | * |
| 121 | * Global Type Definitions |
| 122 | * |
| 123 | ***********************************************************************/ |
| 124 | |
| 125 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_0# { |
| 126 | void *alignedcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_0#aligned.; /* pointer to ie. 128 bit aligned memory */ |
| 127 | void *pointercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_0#pointer.; /* to use with malloc/free */ |
| 128 | } aligned_pointer_tcxx . . $ aligned_pointer_t#; |
| 129 | |
| 130 | void calloc_alignedcxx . . $ calloc_aligned(e8f4ad1733f94427).(aligned_pointer_tcxx . . $ aligned_pointer_t# * ptr, unsigned int size, unsigned int bytes); |
| 131 | void free_alignedcxx . . $ free_aligned(e81f82272f16aa8f).(aligned_pointer_tcxx . . $ aligned_pointer_t# * ptr); |
| 132 | |
| 133 | |
| 134 | /* "bit_stream.h" Type Definitions */ |
| 135 | |
| 136 | typedef struct bit_stream_struccxx . . $ bit_stream_struc# { |
| 137 | unsigned char *bufcxx . . $ bit_stream_struc#buf.; /* bit stream buffer */ |
| 138 | int buf_sizecxx . . $ bit_stream_struc#buf_size.; /* size of buffer (in number of bytes) */ |
| 139 | int totbitcxx . . $ bit_stream_struc#totbit.; /* bit counter of bit stream */ |
| 140 | int buf_byte_idxcxx . . $ bit_stream_struc#buf_byte_idx.; /* pointer to top byte in buffer */ |
| 141 | int buf_bit_idxcxx . . $ bit_stream_struc#buf_bit_idx.; /* pointer to top bit of top byte in buffer */ |
| 142 | |
| 143 | /* format of file in rd mode (BINARY/ASCII) */ |
| 144 | } Bit_stream_struccxx . . $ Bit_stream_struc#; |
| 145 | |
| 146 | |
| 147 | |
| 148 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1# { |
| 149 | int sumcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#sum.; /* what we have seen so far */ |
| 150 | int seencxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#seen.; /* how many frames we have seen in this chunk */ |
| 151 | int wantcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#want.; /* how many frames we want to collect into one chunk */ |
| 152 | int poscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#pos.; /* actual position in our bag */ |
| 153 | int sizecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#size.; /* size of our bag */ |
| 154 | int *bagcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#bag.; /* pointer to our bag */ |
| 155 | unsigned int nVbrNumFramescxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#nVbrNumFrames.; |
| 156 | unsigned long nBytesWrittencxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#nBytesWritten.; |
| 157 | /* VBR tag data */ |
| 158 | unsigned int TotalFrameSizecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_1#TotalFrameSize.; |
| 159 | } VBR_seek_info_tcxx . . $ VBR_seek_info_t#; |
| 160 | |
| 161 | |
| 162 | /** |
| 163 | * ATH related stuff, if something new ATH related has to be added, |
| 164 | * please plugg it here into the ATH_t struct |
| 165 | */ |
| 166 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2# { |
| 167 | int use_adjustcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#use_adjust.; /* method for the auto adjustment */ |
| 168 | FLOATcxx . . $ FLOAT# aa_sensitivity_pcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#aa_sensitivity_p.; /* factor for tuning the (sample power) |
| 169 | point below which adaptive threshold |
| 170 | of hearing adjustment occurs */ |
| 171 | FLOATcxx . . $ FLOAT# adjust_factorcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#adjust_factor.; /* lowering based on peak volume, 1 = no lowering */ |
| 172 | FLOATcxx . . $ FLOAT# adjust_limitcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#adjust_limit.; /* limit for dynamic ATH adjust */ |
| 173 | FLOATcxx . . $ FLOAT# decaycxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#decay.; /* determined to lower x dB each second */ |
| 174 | FLOATcxx . . $ FLOAT# floorcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#floor.; /* lowest ATH value */ |
| 175 | FLOATcxx . . $ FLOAT# lcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#l.[SBMAX_lcxx . . $ `external/lame/encoder.h:103:9`!]; /* ATH for sfbs in long blocks */ |
| 176 | FLOATcxx . . $ FLOAT# scxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#s.[SBMAX_scxx . . $ `external/lame/encoder.h:104:9`!]; /* ATH for sfbs in short blocks */ |
| 177 | FLOATcxx . . $ FLOAT# psfb21cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#psfb21.[PSFB21cxx . . $ `external/lame/encoder.h:105:9`!]; /* ATH for partitionned sfb21 in long blocks */ |
| 178 | FLOATcxx . . $ FLOAT# psfb12cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#psfb12.[PSFB12cxx . . $ `external/lame/encoder.h:106:9`!]; /* ATH for partitionned sfb12 in short blocks */ |
| 179 | FLOATcxx . . $ FLOAT# cb_lcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#cb_l.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; /* ATH for long block convolution bands */ |
| 180 | FLOATcxx . . $ FLOAT# cb_scxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#cb_s.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; /* ATH for short block convolution bands */ |
| 181 | FLOATcxx . . $ FLOAT# eql_wcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_2#eql_w.[BLKSIZEcxx . . $ `external/lame/encoder.h:111:9`! / 2]; /* equal loudness weights (based on ATH) */ |
| 182 | } ATH_tcxx . . $ ATH_t#; |
| 183 | |
| 184 | /** |
| 185 | * PSY Model related stuff |
| 186 | */ |
| 187 | |
| 188 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3# { |
| 189 | FLOATcxx . . $ FLOAT# masking_lowercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#masking_lower.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 190 | FLOATcxx . . $ FLOAT# minvalcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#minval.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 191 | FLOATcxx . . $ FLOAT# rnumlinescxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#rnumlines.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 192 | FLOATcxx . . $ FLOAT# mld_cbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#mld_cb.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 193 | FLOATcxx . . $ FLOAT# mldcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#mld.[Maxcxx . . $ `external/lame/util.h:92:17`!(SBMAX_lcxx . . $ `external/lame/encoder.h:103:9`!,SBMAX_scxx . . $ `external/lame/encoder.h:104:9`!)]; |
| 194 | FLOATcxx . . $ FLOAT# bo_weightcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#bo_weight.[Maxcxx . . $ `external/lame/util.h:92:17`!(SBMAX_lcxx . . $ `external/lame/encoder.h:103:9`!,SBMAX_scxx . . $ `external/lame/encoder.h:104:9`!)]; /* band weight long scalefactor bands, at transition */ |
| 195 | FLOATcxx . . $ FLOAT# attack_thresholdcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#attack_threshold.; /* short block tuning */ |
| 196 | int s3indcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#s3ind.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!][2]; |
| 197 | int numlinescxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#numlines.[CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 198 | int bmcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#bm.[Maxcxx . . $ `external/lame/util.h:92:17`!(SBMAX_lcxx . . $ `external/lame/encoder.h:103:9`!,SBMAX_scxx . . $ `external/lame/encoder.h:104:9`!)]; |
| 199 | int bocxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#bo.[Maxcxx . . $ `external/lame/util.h:92:17`!(SBMAX_lcxx . . $ `external/lame/encoder.h:103:9`!,SBMAX_scxx . . $ `external/lame/encoder.h:104:9`!)]; |
| 200 | int npartcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#npart.; |
| 201 | int n_sbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#n_sb.; /* SBMAX_l or SBMAX_s */ |
| 202 | FLOATcxx . . $ FLOAT# *s3cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_3#s3.; |
| 203 | } PsyConst_CB2SB_tcxx . . $ PsyConst_CB2SB_t#; |
| 204 | |
| 205 | |
| 206 | /** |
| 207 | * global data constants |
| 208 | */ |
| 209 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4# { |
| 210 | FLOATcxx . . $ FLOAT# windowcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#window.[BLKSIZEcxx . . $ `external/lame/encoder.h:111:9`!], window_scxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#window_s.[BLKSIZE_scxx . . $ `external/lame/encoder.h:113:9`! / 2]; |
| 211 | PsyConst_CB2SB_tcxx . . $ PsyConst_CB2SB_t# lcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#l.; |
| 212 | PsyConst_CB2SB_tcxx . . $ PsyConst_CB2SB_t# scxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#s.; |
| 213 | PsyConst_CB2SB_tcxx . . $ PsyConst_CB2SB_t# l_to_scxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#l_to_s.; |
| 214 | FLOATcxx . . $ FLOAT# attack_thresholdcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#attack_threshold.[4]; |
| 215 | FLOATcxx . . $ FLOAT# decaycxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#decay.; |
| 216 | int force_short_block_calccxx . . $ $anonymous_type_fa6ce02aa65ebf3c_4#force_short_block_calc.; |
| 217 | } PsyConst_tcxx . . $ PsyConst_t#; |
| 218 | |
| 219 | |
| 220 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5# { |
| 221 | |
| 222 | FLOATcxx . . $ FLOAT# nb_l1cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#nb_l1.[4][CBANDScxx . . $ `external/lame/encoder.h:96:9`!], nb_l2cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#nb_l2.[4][CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 223 | FLOATcxx . . $ FLOAT# nb_s1cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#nb_s1.[4][CBANDScxx . . $ `external/lame/encoder.h:96:9`!], nb_s2cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#nb_s2.[4][CBANDScxx . . $ `external/lame/encoder.h:96:9`!]; |
| 224 | |
| 225 | III_psy_xmincxx . . $ III_psy_xmin# thmcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#thm.[4]; |
| 226 | III_psy_xmincxx . . $ III_psy_xmin# encxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#en.[4]; |
| 227 | |
| 228 | /* loudness calculation (for adaptive threshold of hearing) */ |
| 229 | FLOATcxx . . $ FLOAT# loudness_sq_savecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#loudness_sq_save.[2]; /* account for granule delay of L3psycho_anal */ |
| 230 | |
| 231 | FLOATcxx . . $ FLOAT# tot_enercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#tot_ener.[4]; |
| 232 | |
| 233 | FLOATcxx . . $ FLOAT# last_en_subshortcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#last_en_subshort.[4][9]; |
| 234 | int last_attackscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#last_attacks.[4]; |
| 235 | |
| 236 | int blocktype_oldcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_5#blocktype_old.[2]; |
| 237 | } PsyStateVar_tcxx . . $ PsyStateVar_t#; |
| 238 | |
| 239 | |
| 240 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_6# { |
| 241 | /* loudness calculation (for adaptive threshold of hearing) */ |
| 242 | FLOATcxx . . $ FLOAT# loudness_sqcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_6#loudness_sq.[2][2]; /* loudness^2 approx. per granule and channel */ |
| 243 | } PsyResult_tcxx . . $ PsyResult_t#; |
| 244 | |
| 245 | |
| 246 | /* variables used by encoder.c */ |
| 247 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7# { |
| 248 | /* variables for newmdct.c */ |
| 249 | FLOATcxx . . $ FLOAT# sb_samplecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#sb_sample.[2][2][18][SBLIMITcxx . . $ `external/lame/encoder.h:93:9`!]; |
| 250 | FLOATcxx . . $ FLOAT# amp_filtercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#amp_filter.[32]; |
| 251 | |
| 252 | /* variables used by util.c */ |
| 253 | /* BPC = maximum number of filter convolution windows to precompute */ |
| 254 | #define BPCcxx . . $ `external/lame/util.h:254:9`! 320 |
| 255 | double itimecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#itime.[2]; /* float precision seems to be not enough */ |
| 256 | sample_tcxx . . $ sample_t# *inbuf_oldcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#inbuf_old.[2]; |
| 257 | sample_tcxx . . $ sample_t# *blackfiltcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#blackfilt.[2 * BPCcxx . . $ `external/lame/util.h:254:9`! + 1]; |
| 258 | |
| 259 | FLOATcxx . . $ FLOAT# pefirbufcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#pefirbuf.[19]; |
| 260 | |
| 261 | /* used for padding */ |
| 262 | int frac_SpFcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#frac_SpF.; |
| 263 | int slot_lagcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#slot_lag.; |
| 264 | |
| 265 | /* variables for bitstream.c */ |
| 266 | /* mpeg1: buffer=511 bytes smallest frame: 96-38(sideinfo)=58 |
| 267 | * max number of frames in reservoir: 8 |
| 268 | * mpeg2: buffer=255 bytes. smallest frame: 24-23bytes=1 |
| 269 | * with VBR, if you are encoding all silence, it is possible to |
| 270 | * have 8kbs/24khz frames with 1byte of data each, which means we need |
| 271 | * to buffer up to 255 headers! */ |
| 272 | /* also, max_header_buf has to be a power of two */ |
| 273 | #define MAX_HEADER_BUFcxx . . $ `external/lame/util.h:273:9`! 256 |
| 274 | #define MAX_HEADER_LENcxx . . $ `external/lame/util.h:274:9`! 40 /* max size of header is 38 */ |
| 275 | structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#$anonymous_type_8# { |
| 276 | int write_timingcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#$anonymous_type_8#write_timing.; |
| 277 | int ptrcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#$anonymous_type_8#ptr.; |
| 278 | char bufcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#$anonymous_type_8#buf.[MAX_HEADER_LENcxx . . $ `external/lame/util.h:274:9`!]; |
| 279 | } headercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#header.[MAX_HEADER_BUFcxx . . $ `external/lame/util.h:273:9`!]; |
| 280 | |
| 281 | int h_ptrcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#h_ptr.; |
| 282 | int w_ptrcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#w_ptr.; |
| 283 | int ancillary_flagcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#ancillary_flag.; |
| 284 | |
| 285 | /* variables for reservoir.c */ |
| 286 | int ResvSizecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#ResvSize.; /* in bits */ |
| 287 | int ResvMaxcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#ResvMax.; /* in bits */ |
| 288 | |
| 289 | int in_buffer_nsamplescxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#in_buffer_nsamples.; |
| 290 | sample_tcxx . . $ sample_t# *in_buffer_0cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#in_buffer_0.; |
| 291 | sample_tcxx . . $ sample_t# *in_buffer_1cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#in_buffer_1.; |
| 292 | |
| 293 | #ifndef MFSIZE |
| 294 | # define MFSIZEcxx . . $ `external/lame/util.h:294:10`! ( 3*1152 + ENCDELAYcxx . . $ `external/lame/encoder.h:57:9`! - MDCTDELAYcxx . . $ `external/lame/encoder.h:82:9`! ) |
| 295 | #endif |
| 296 | sample_tcxx . . $ sample_t# mfbufcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#mfbuf.[2][MFSIZEcxx . . $ `external/lame/util.h:294:10`!]; |
| 297 | |
| 298 | int mf_samples_to_encodecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#mf_samples_to_encode.; |
| 299 | int mf_sizecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_7#mf_size.; |
| 300 | |
| 301 | } EncStateVar_tcxx . . $ EncStateVar_t#; |
| 302 | |
| 303 | |
| 304 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9# { |
| 305 | /* simple statistics */ |
| 306 | int bitrate_channelmode_histcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#bitrate_channelmode_hist.[16][4 + 1]; |
| 307 | int bitrate_blocktype_histcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#bitrate_blocktype_hist.[16][4 + 1 + 1]; /*norm/start/short/stop/mixed(short)/sum */ |
| 308 | |
| 309 | int bitrate_indexcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#bitrate_index.; |
| 310 | int frame_numbercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#frame_number.; /* number of frames encoded */ |
| 311 | int paddingcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#padding.; /* padding for the current frame? */ |
| 312 | int mode_extcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#mode_ext.; |
| 313 | int encoder_delaycxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#encoder_delay.; |
| 314 | int encoder_paddingcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_9#encoder_padding.; /* number of samples of padding appended to input */ |
| 315 | } EncResult_tcxx . . $ EncResult_t#; |
| 316 | |
| 317 | |
| 318 | /* variables used by quantize.c */ |
| 319 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10# { |
| 320 | /* variables for nspsytune */ |
| 321 | FLOATcxx . . $ FLOAT# longfactcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#longfact.[SBMAX_lcxx . . $ `external/lame/encoder.h:103:9`!]; |
| 322 | FLOATcxx . . $ FLOAT# shortfactcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#shortfact.[SBMAX_scxx . . $ `external/lame/encoder.h:104:9`!]; |
| 323 | FLOATcxx . . $ FLOAT# masking_lowercxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#masking_lower.; |
| 324 | FLOATcxx . . $ FLOAT# mask_adjustcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#mask_adjust.; /* the dbQ stuff */ |
| 325 | FLOATcxx . . $ FLOAT# mask_adjust_shortcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#mask_adjust_short.; /* the dbQ stuff */ |
| 326 | int OldValuecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#OldValue.[2]; |
| 327 | int CurrentStepcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#CurrentStep.[2]; |
| 328 | int pseudohalfcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#pseudohalf.[SFBMAXcxx . . $ `external/lame/l3side.h:26:9`!]; |
| 329 | int sfb21_extracxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#sfb21_extra.; /* will be set in lame_init_params */ |
| 330 | int substep_shapingcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#substep_shaping.; /* 0 = no substep |
| 331 | 1 = use substep shaping at last step(VBR only) |
| 332 | (not implemented yet) |
| 333 | 2 = use substep inside loop |
| 334 | 3 = use substep inside loop and last step |
| 335 | */ |
| 336 | |
| 337 | |
| 338 | char bv_scfcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_10#bv_scf.[576]; |
| 339 | } QntStateVar_tcxx . . $ QntStateVar_t#; |
| 340 | |
| 341 | |
| 342 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_11# { |
| 343 | replaygain_tcxx . . $ replaygain_t# *rgdatacxx . . $ $anonymous_type_fa6ce02aa65ebf3c_11#rgdata.; |
| 344 | /* ReplayGain */ |
| 345 | } RpgStateVar_tcxx . . $ RpgStateVar_t#; |
| 346 | |
| 347 | |
| 348 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_12# { |
| 349 | FLOATcxx . . $ FLOAT# noclipScalecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_12#noclipScale.; /* user-specified scale factor required for preventing clipping */ |
| 350 | sample_tcxx . . $ sample_t# PeakSamplecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_12#PeakSample.; |
| 351 | int RadioGaincxx . . $ $anonymous_type_fa6ce02aa65ebf3c_12#RadioGain.; |
| 352 | int noclipGainChangecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_12#noclipGainChange.; /* gain change required for preventing clipping */ |
| 353 | } RpgResult_tcxx . . $ RpgResult_t#; |
| 354 | |
| 355 | |
| 356 | typedef structcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13# { |
| 357 | int versioncxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#version.; /* 0=MPEG-2/2.5 1=MPEG-1 */ |
| 358 | int samplerate_indexcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#samplerate_index.; |
| 359 | int sideinfo_lencxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#sideinfo_len.; |
| 360 | |
| 361 | int noise_shapingcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#noise_shaping.; /* 0 = none |
| 362 | 1 = ISO AAC model |
| 363 | 2 = allow scalefac_select=1 |
| 364 | */ |
| 365 | |
| 366 | int subblock_gaincxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#subblock_gain.; /* 0 = no, 1 = yes */ |
| 367 | int use_best_huffmancxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#use_best_huffman.; /* 0 = no. 1=outside loop 2=inside loop(slow) */ |
| 368 | int noise_shaping_ampcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#noise_shaping_amp.; /* 0 = ISO model: amplify all distorted bands |
| 369 | 1 = amplify within 50% of max (on db scale) |
| 370 | 2 = amplify only most distorted band |
| 371 | 3 = method 1 and refine with method 2 |
| 372 | */ |
| 373 | |
| 374 | int noise_shaping_stopcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#noise_shaping_stop.; /* 0 = stop at over=0, all scalefacs amplified or |
| 375 | a scalefac has reached max value |
| 376 | 1 = stop when all scalefacs amplified or |
| 377 | a scalefac has reached max value |
| 378 | 2 = stop when all scalefacs amplified |
| 379 | */ |
| 380 | |
| 381 | |
| 382 | int full_outer_loopcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#full_outer_loop.; /* 0 = stop early after 0 distortion found. 1 = full search */ |
| 383 | |
| 384 | int lowpassfreqcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#lowpassfreq.; |
| 385 | int highpassfreqcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#highpassfreq.; |
| 386 | int samplerate_incxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#samplerate_in.; /* input_samp_rate in Hz. default=44.1 kHz */ |
| 387 | int samplerate_outcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#samplerate_out.; /* output_samp_rate. */ |
| 388 | int channels_incxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#channels_in.; /* number of channels in the input data stream (PCM or decoded PCM) */ |
| 389 | int channels_outcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#channels_out.; /* number of channels in the output data stream (not used for decoding) */ |
| 390 | int mode_grcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#mode_gr.; /* granules per frame */ |
| 391 | int force_mscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#force_ms.; /* force M/S mode. requires mode=1 */ |
| 392 | |
| 393 | int quant_compcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#quant_comp.; |
| 394 | int quant_comp_shortcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#quant_comp_short.; |
| 395 | |
| 396 | int use_temporal_masking_effectcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#use_temporal_masking_effect.; |
| 397 | int use_safe_joint_stereocxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#use_safe_joint_stereo.; |
| 398 | |
| 399 | int presetcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#preset.; |
| 400 | |
| 401 | vbr_modecxx . . $ vbr_mode# vbrcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#vbr.; |
| 402 | int vbr_avg_bitrate_kbpscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#vbr_avg_bitrate_kbps.; |
| 403 | int vbr_min_bitrate_indexcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#vbr_min_bitrate_index.; /* min bitrate index */ |
| 404 | int vbr_max_bitrate_indexcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#vbr_max_bitrate_index.; /* max bitrate index */ |
| 405 | int avg_bitratecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#avg_bitrate.; |
| 406 | int enforce_min_bitratecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#enforce_min_bitrate.; /* strictly enforce VBR_min_bitrate normaly, it will be violated for analog silence */ |
| 407 | |
| 408 | int findReplayGaincxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#findReplayGain.; /* find the RG value? default=0 */ |
| 409 | int findPeakSamplecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#findPeakSample.; |
| 410 | int decode_on_the_flycxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#decode_on_the_fly.; /* decode on the fly? default=0 */ |
| 411 | int analysiscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#analysis.; |
| 412 | int disable_reservoircxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#disable_reservoir.; |
| 413 | int buffer_constraintcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#buffer_constraint.; /* enforce ISO spec as much as possible */ |
| 414 | int free_formatcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#free_format.; |
| 415 | int write_lame_tagcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#write_lame_tag.; /* add Xing VBR tag? */ |
| 416 | |
| 417 | int error_protectioncxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#error_protection.; /* use 2 bytes per frame for a CRC checksum. default=0 */ |
| 418 | int copyrightcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#copyright.; /* mark as copyright. default=0 */ |
| 419 | int originalcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#original.; /* mark as original. default=1 */ |
| 420 | int extensioncxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#extension.; /* the MP3 'private extension' bit. Meaningless */ |
| 421 | int emphasiscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#emphasis.; /* Input PCM is emphased PCM (for |
| 422 | instance from one of the rarely |
| 423 | emphased CDs), it is STRONGLY not |
| 424 | recommended to use this, because |
| 425 | psycho does not take it into account, |
| 426 | and last but not least many decoders |
| 427 | don't care about these bits */ |
| 428 | |
| 429 | |
| 430 | MPEG_modecxx . . $ MPEG_mode# modecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#mode.; |
| 431 | short_block_tcxx . . $ short_block_t# short_blockscxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#short_blocks.; |
| 432 | |
| 433 | float interChRatiocxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#interChRatio.; |
| 434 | float msfixcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#msfix.; /* Naoki's adjustment of Mid/Side maskings */ |
| 435 | float ATH_offset_dbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATH_offset_db.;/* add to ATH this many db */ |
| 436 | float ATH_offset_factorcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATH_offset_factor.;/* change ATH by this factor, derived from ATH_offset_db */ |
| 437 | float ATHcurvecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATHcurve.; /* change ATH formula 4 shape */ |
| 438 | int ATHtypecxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATHtype.; |
| 439 | int ATHonlycxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATHonly.; /* only use ATH */ |
| 440 | int ATHshortcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATHshort.; /* only use ATH for short blocks */ |
| 441 | int noATHcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#noATH.; /* disable ATH */ |
| 442 | |
| 443 | float ATHfixpointcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#ATHfixpoint.; |
| 444 | |
| 445 | float adjust_alto_dbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#adjust_alto_db.; |
| 446 | float adjust_bass_dbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#adjust_bass_db.; |
| 447 | float adjust_treble_dbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#adjust_treble_db.; |
| 448 | float adjust_sfb21_dbcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#adjust_sfb21_db.; |
| 449 | |
| 450 | float compression_ratiocxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#compression_ratio.; /* sizeof(wav file)/sizeof(mp3 file) */ |
| 451 | |
| 452 | /* lowpass and highpass filter control */ |
| 453 | FLOATcxx . . $ FLOAT# lowpass1cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#lowpass1., lowpass2cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#lowpass2.; /* normalized frequency bounds of passband */ |
| 454 | FLOATcxx . . $ FLOAT# highpass1cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#highpass1., highpass2cxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#highpass2.; /* normalized frequency bounds of passband */ |
| 455 | |
| 456 | /* scale input by this amount before encoding at least not used for MP3 decoding */ |
| 457 | FLOATcxx . . $ FLOAT# pcm_transformcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#pcm_transform.[2][2]; |
| 458 | |
| 459 | FLOATcxx . . $ FLOAT# minvalcxx . . $ $anonymous_type_fa6ce02aa65ebf3c_13#minval.; |
| 460 | } SessionConfig_tcxx . . $ SessionConfig_t#; |
| 461 | |
| 462 | |
| 463 | struct lame_internal_flagscxx . . $ lame_internal_flags# { |
| 464 | |
| 465 | /******************************************************************** |
| 466 | * internal variables NOT set by calling program, and should not be * |
| 467 | * modified by the calling program * |
| 468 | ********************************************************************/ |
| 469 | |
| 470 | /* |
| 471 | * Some remarks to the Class_ID field: |
| 472 | * The Class ID is an Identifier for a pointer to this struct. |
| 473 | * It is very unlikely that a pointer to lame_global_flags has the same 32 bits |
| 474 | * in it's structure (large and other special properties, for instance prime). |
| 475 | * |
| 476 | * To test that the structure is right and initialized, use: |
| 477 | * if ( gfc -> Class_ID == LAME_ID ) ... |
| 478 | * Other remark: |
| 479 | * If you set a flag to 0 for uninit data and 1 for init data, the right test |
| 480 | * should be "if (flag == 1)" and NOT "if (flag)". Unintended modification |
| 481 | * of this element will be otherwise misinterpreted as an init. |
| 482 | */ |
| 483 | # define LAME_IDcxx . . $ `external/lame/util.h:483:12`! 0xFFF88E3B |
| 484 | unsigned long class_idcxx . . $ lame_internal_flags#class_id.; |
| 485 | |
| 486 | int lame_init_params_successfulcxx . . $ lame_internal_flags#lame_init_params_successful.; |
| 487 | int lame_encode_frame_initcxx . . $ lame_internal_flags#lame_encode_frame_init.; |
| 488 | int iteration_init_initcxx . . $ lame_internal_flags#iteration_init_init.; |
| 489 | int fill_buffer_resample_initcxx . . $ lame_internal_flags#fill_buffer_resample_init.; |
| 490 | |
| 491 | SessionConfig_tcxx . . $ SessionConfig_t# cfgcxx . . $ lame_internal_flags#cfg.; |
| 492 | |
| 493 | /* variables used by lame.c */ |
| 494 | Bit_stream_struccxx . . $ Bit_stream_struc# bscxx . . $ lame_internal_flags#bs.; |
| 495 | III_side_info_tcxx . . $ III_side_info_t# l3_sidecxx . . $ lame_internal_flags#l3_side.; |
| 496 | |
| 497 | scalefac_structcxx . . $ scalefac_struct# scalefac_bandcxx . . $ lame_internal_flags#scalefac_band.; |
| 498 | |
| 499 | PsyStateVar_tcxx . . $ PsyStateVar_t# sv_psycxx . . $ lame_internal_flags#sv_psy.; /* DATA FROM PSYMODEL.C */ |
| 500 | PsyResult_tcxx . . $ PsyResult_t# ov_psycxx . . $ lame_internal_flags#ov_psy.; |
| 501 | EncStateVar_tcxx . . $ EncStateVar_t# sv_enccxx . . $ lame_internal_flags#sv_enc.; /* DATA FROM ENCODER.C */ |
| 502 | EncResult_tcxx . . $ EncResult_t# ov_enccxx . . $ lame_internal_flags#ov_enc.; |
| 503 | QntStateVar_tcxx . . $ QntStateVar_t# sv_qntcxx . . $ lame_internal_flags#sv_qnt.; /* DATA FROM QUANTIZE.C */ |
| 504 | |
| 505 | RpgStateVar_tcxx . . $ RpgStateVar_t# sv_rpgcxx . . $ lame_internal_flags#sv_rpg.; |
| 506 | RpgResult_tcxx . . $ RpgResult_t# ov_rpgcxx . . $ lame_internal_flags#ov_rpg.; |
| 507 | |
| 508 | /* optional ID3 tags, used in id3tag.c */ |
| 509 | struct id3tag_speccxx . . $ id3tag_spec# tag_speccxx . . $ lame_internal_flags#tag_spec.; |
| 510 | uint16_tcxx . . $ uint16_t# nMusicCRCcxx . . $ lame_internal_flags#nMusicCRC.; |
| 511 | |
| 512 | uint16_tcxx . . $ uint16_t# _unusedcxx . . $ lame_internal_flags#_unused.; |
| 513 | |
| 514 | /* CPU features */ |
| 515 | structcxx . . $ lame_internal_flags#$anonymous_type_14# { |
| 516 | unsigned int MMXcxx . . $ lame_internal_flags#$anonymous_type_14#MMX.:1; /* Pentium MMX, Pentium II...IV, K6, K6-2, |
| 517 | K6-III, Athlon */ |
| 518 | unsigned int AMD_3DNowcxx . . $ lame_internal_flags#$anonymous_type_14#AMD_3DNow.:1; /* K6-2, K6-III, Athlon */ |
| 519 | unsigned int SSEcxx . . $ lame_internal_flags#$anonymous_type_14#SSE.:1; /* Pentium III, Pentium 4 */ |
| 520 | unsigned int SSE2cxx . . $ lame_internal_flags#$anonymous_type_14#SSE2.:1; /* Pentium 4, K8 */ |
| 521 | unsigned int _unusedcxx . . $ lame_internal_flags#$anonymous_type_14#_unused.:28; |
| 522 | } CPU_featurescxx . . $ lame_internal_flags#CPU_features.; |
| 523 | |
| 524 | |
| 525 | VBR_seek_info_tcxx . . $ VBR_seek_info_t# VBR_seek_tablecxx . . $ lame_internal_flags#VBR_seek_table.; /* used for Xing VBR header */ |
| 526 | |
| 527 | ATH_tcxx . . $ ATH_t# *ATHcxx . . $ lame_internal_flags#ATH.; /* all ATH related stuff */ |
| 528 | |
| 529 | PsyConst_tcxx . . $ PsyConst_t# *cd_psycxx . . $ lame_internal_flags#cd_psy.; |
| 530 | |
| 531 | /* used by the frame analyzer */ |
| 532 | plotting_datacxx . . $ plotting_data# *pinfocxx . . $ lame_internal_flags#pinfo.; |
| 533 | hip_tcxx . . $ hip_t# hipcxx . . $ lame_internal_flags#hip.; |
| 534 | |
| 535 | /* functions to replace with CPU feature optimized versions in takehiro.c */ |
| 536 | int (*choose_tablecxx . . $ lame_internal_flags#choose_table.) (const int *ix, const int *const end, int *const s); |
| 537 | void (*fft_fhtcxx . . $ lame_internal_flags#fft_fht.) (FLOATcxx . . $ FLOAT# *, int); |
| 538 | void (*init_xrpow_corecxx . . $ lame_internal_flags#init_xrpow_core.) (gr_infocxx . . $ gr_info# * const cod_info, FLOATcxx . . $ FLOAT# xrpow[576], int upper, |
| 539 | FLOATcxx . . $ FLOAT# * sum); |
| 540 | |
| 541 | lame_report_functioncxx . . $ lame_report_function# report_msgcxx . . $ lame_internal_flags#report_msg.; |
| 542 | lame_report_functioncxx . . $ lame_report_function# report_dbgcxx . . $ lame_internal_flags#report_dbg.; |
| 543 | lame_report_functioncxx . . $ lame_report_function# report_errcxx . . $ lame_internal_flags#report_err.; |
| 544 | }; |
| 545 | |
| 546 | #ifndef lame_internal_flags_definedcxx . . $ `external/lame/encoder.h:147:9`! |
| 547 | #define lame_internal_flags_defined |
| 548 | typedef struct lame_internal_flags lame_internal_flags; |
| 549 | #endif |
| 550 | |
| 551 | |
| 552 | /*********************************************************************** |
| 553 | * |
| 554 | * Global Function Prototype Declarations |
| 555 | * |
| 556 | ***********************************************************************/ |
| 557 | void freegfccxx . . $ freegfc(4f558d83b2842a93).(lame_internal_flagscxx . . $ lame_internal_flags# * const gfc); |
| 558 | void free_id3tagcxx . . $ free_id3tag(4f558d83b2842a93).(lame_internal_flagscxx . . $ lame_internal_flags# * const gfc); |
| 559 | extern int BitrateIndexcxx . . $ BitrateIndex(2326284602b0bb2d).(int, int, int); |
| 560 | extern int FindNearestBitratecxx . . $ FindNearestBitrate(2326284602b0bb2d).(int, int, int); |
| 561 | extern int map2MP3Frequencycxx . . $ map2MP3Frequency(7864480464b09eea).(int freq); |
| 562 | extern int SmpFrqIndexcxx . . $ SmpFrqIndex(ac48f4a6ffa9e770).(int, int *const); |
| 563 | extern int nearestBitrateFullIndexcxx . . $ nearestBitrateFullIndex(377f6a3136964dac).(uint16_tcxx . . $ uint16_t# brate); |
| 564 | extern FLOATcxx . . $ FLOAT# ATHformulacxx . . $ ATHformula(e110220ec0e8c77a).(SessionConfig_tcxx . . $ SessionConfig_t# const *cfg, FLOATcxx . . $ FLOAT# freq); |
| 565 | extern FLOATcxx . . $ FLOAT# freq2barkcxx . . $ freq2bark(fbcf3211dfe1bfd1).(FLOATcxx . . $ FLOAT# freq); |
| 566 | void disable_FPEcxx . . $ disable_FPE(49f6e7a06ebc5aa8).(void); |
| 567 | |
| 568 | /* log/log10 approximations */ |
| 569 | extern void init_log_tablecxx . . $ init_log_table(49f6e7a06ebc5aa8).(void); |
| 570 | extern ieee754_float32_tcxx . . $ ieee754_float32_t# fast_log2cxx . . $ fast_log2(fbcf3211dfe1bfd1).(ieee754_float32_tcxx . . $ ieee754_float32_t# x); |
| 571 | |
| 572 | int isResamplingNecessarycxx . . $ isResamplingNecessary(3353a2dd70c7b2e6).(SessionConfig_tcxx . . $ SessionConfig_t# const* cfg); |
| 573 | |
| 574 | void fill_buffercxx . . $ fill_buffer(a28439526dc95a64).(lame_internal_flagscxx . . $ lame_internal_flags# * gfc, |
| 575 | sample_tcxx . . $ sample_t# *const mfbuf[2], |
| 576 | sample_tcxx . . $ sample_t# const *const in_buffer[2], int nsamples, int *n_in, int *n_out); |
| 577 | |
| 578 | /* same as lame_decode1 (look in lame.h), but returns |
| 579 | unclipped raw floating-point samples. It is declared |
| 580 | here, not in lame.h, because it returns LAME's |
| 581 | internal type sample_t. No more than 1152 samples |
| 582 | per channel are allowed. */ |
| 583 | int hip_decode1_unclippedcxx . . $ hip_decode1_unclipped(fc8e5ffa25bd4456).(hip_tcxx . . $ hip_t# hip, unsigned char *mp3buf, |
| 584 | size_t len, sample_tcxx . . $ sample_t# pcm_l[], sample_tcxx . . $ sample_t# pcm_r[]); |
| 585 | |
| 586 | |
| 587 | extern int has_MMXcxx . . $ has_MMX(b126dc7c1de90089).(void); |
| 588 | extern int has_3DNowcxx . . $ has_3DNow(b126dc7c1de90089).(void); |
| 589 | extern int has_SSEcxx . . $ has_SSE(b126dc7c1de90089).(void); |
| 590 | extern int has_SSE2cxx . . $ has_SSE2(b126dc7c1de90089).(void); |
| 591 | |
| 592 | |
| 593 | |
| 594 | /*********************************************************************** |
| 595 | * |
| 596 | * Macros about Message Printing and Exit |
| 597 | * |
| 598 | ***********************************************************************/ |
| 599 | |
| 600 | extern void lame_report_defcxx . . $ lame_report_def(ac175dd46a4e4d7f).(const char* format, va_listcxx . . $ va_list# args); |
| 601 | extern void lame_report_fnccxx . . $ lame_report_fnc(eff5491a82813ecf).(lame_report_functioncxx . . $ lame_report_function# print_f, const char *, ...); |
| 602 | extern void lame_errorfcxx . . $ lame_errorf(9ec3808e79d7f8bc).(const lame_internal_flagscxx . . $ lame_internal_flags# * gfc, const char *, ...); |
| 603 | extern void lame_debugfcxx . . $ lame_debugf(9ec3808e79d7f8bc).(const lame_internal_flagscxx . . $ lame_internal_flags# * gfc, const char *, ...); |
| 604 | extern void lame_msgfcxx . . $ lame_msgf(9ec3808e79d7f8bc).(const lame_internal_flagscxx . . $ lame_internal_flags# * gfc, const char *, ...); |
| 605 | #define DEBUGFcxx . . $ `external/lame/util.h:605:9`! lame_debugf |
| 606 | #define ERRORFcxx . . $ `external/lame/util.h:606:9`! lame_errorf |
| 607 | #define MSGFcxx . . $ `external/lame/util.h:607:9`! lame_msgf |
| 608 | |
| 609 | int is_lame_internal_flags_validcxx . . $ is_lame_internal_flags_valid(b815612886108da).(const lame_internal_flagscxx . . $ lame_internal_flags# * gfp); |
| 610 | |
| 611 | extern void hip_set_pinfocxx . . $ hip_set_pinfo(c9c1dfdfcdf4fe74).(hip_tcxx . . $ hip_t# hip, plotting_datacxx . . $ plotting_data#* pinfo); |
| 612 | |
| 613 | #ifdef __cplusplus |
| 614 | } |
| 615 | #endif |
| 616 | #endif /* LAME_UTIL_H */ |