Loading lib_lc3plus/adjust_global_gain.c +16 −6 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading @@ -15,11 +15,14 @@ void processAdjustGlobalGain_fl(LC3_INT* gg_idx, LC3_INT gg_idx_min, LC3_INT gg_ , LC3_INT16 hrmode, LC3_INT16 frame_dms ) { LC3_FLOAT delta = 0; LC3_INT delta2 = 0; LC3_FLOAT delta; LC3_INT delta2; LC3_INT gg_idx_inc; #ifdef CR8_G_ADD_75MS LC3_FLOAT factor; #else LC3_INT factor; #endif if (frame_dms == 25) { Loading @@ -32,7 +35,14 @@ void processAdjustGlobalGain_fl(LC3_INT* gg_idx, LC3_INT gg_idx_min, LC3_INT gg_ } else if (frame_dms == 50) { factor = 2; } else } #ifdef CR8_G_ADD_75MS else if (frame_dms == 75) { factor = 1.2; } #endif else { factor = 1; } Loading Loading @@ -60,7 +70,7 @@ void processAdjustGlobalGain_fl(LC3_INT* gg_idx, LC3_INT gg_idx_min, LC3_INT gg_ if (hrmode) { if (nBits > target) { gg_idx_inc = (int) factor * (((nBits - target)/ delta) + 1); gg_idx_inc = (int) (factor * (((nBits - target)/ delta) + 1)); gg_idx_inc = MIN(gg_idx_inc, 10 * factor); *gg_idx += gg_idx_inc; Loading lib_lc3plus/al_fec_fl.c +1 −1 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading lib_lc3plus/apply_global_gain.c +2 −2 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading @@ -13,7 +13,7 @@ void processApplyGlobalGain_fl(LC3_FLOAT x[], LC3_INT xLen, LC3_INT global_gain_idx, LC3_INT global_gain_off) { LC3_FLOAT gg = 0; LC3_FLOAT gg; gg = LC3_POW(10, (LC3_FLOAT)(global_gain_idx + global_gain_off) / 28); Loading lib_lc3plus/ari_codec.c +807 −154 File changed.Preview size limit exceeded, changes collapsed. Show changes lib_lc3plus/attack_detector.c +12 −26 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading @@ -14,26 +14,19 @@ void attack_detector_fl(LC3_FLOAT* in, LC3_INT frame_size, LC3_INT fs, LC3_INT* lastAttackPosition, LC3_FLOAT* accNrg, LC3_INT* attackFlag, LC3_FLOAT* attdec_filter_mem, LC3_INT attackHandlingOn, LC3_INT attdec_nblocks, LC3_INT attdec_hangover_threshold) { LC3_FLOAT f_sig[160] = {0}, block_nrg[4] = {0}, sum = 0, tmpEne = 0, *ptr = NULL, tmp[162] = {0}; LC3_INT i = 0, j = 0, attackPosition = 0; LC3_FLOAT mval = 0; LC3_INT frame_size_16k = attdec_nblocks * 40; LC3_FLOAT f_sig[160], block_nrg[4], sum, tmpEne, *ptr, tmp[162]; LC3_INT i, j, attackPosition; LC3_FLOAT mval; LC3_INT frame_size_16k; if (attackHandlingOn) { mval = 0; j = 0; frame_size_16k = attdec_nblocks * 40; ptr = &tmp[2]; if (attackHandlingOn) { /* Decimate 96, 48 and 32 kHz signals to 16 kHz */ if (fs == 96000) { for (i = 0; i < frame_size;) { ptr[j] = in[i] + in[i + 1] + in[i + 2] + in[i + 3] + in[i + 4] + in[i + 5]; i = i + 6; j++; } mval = 1e-5; } else if (fs == 48000) { /* Decimate 48 and 32 kHz signals to 16 kHz */ if (fs == 48000) { j = 0; for (i = 0; i < frame_size;) { ptr[j] = (in[i] + in[i + 1] + in[i + 2]); Loading @@ -47,13 +40,6 @@ void attack_detector_fl(LC3_FLOAT* in, LC3_INT frame_size, LC3_INT fs, LC3_INT* i = i + 2; j++; } } else if (fs == 24000) { j = 0; for (i = 0; i < frame_size;) { ptr[j] = (in[i] + (in[i + 1] + in[i + 2]) / 2.0); i = i + 3; j++; } } /* Filter */ Loading Loading
lib_lc3plus/adjust_global_gain.c +16 −6 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading @@ -15,11 +15,14 @@ void processAdjustGlobalGain_fl(LC3_INT* gg_idx, LC3_INT gg_idx_min, LC3_INT gg_ , LC3_INT16 hrmode, LC3_INT16 frame_dms ) { LC3_FLOAT delta = 0; LC3_INT delta2 = 0; LC3_FLOAT delta; LC3_INT delta2; LC3_INT gg_idx_inc; #ifdef CR8_G_ADD_75MS LC3_FLOAT factor; #else LC3_INT factor; #endif if (frame_dms == 25) { Loading @@ -32,7 +35,14 @@ void processAdjustGlobalGain_fl(LC3_INT* gg_idx, LC3_INT gg_idx_min, LC3_INT gg_ } else if (frame_dms == 50) { factor = 2; } else } #ifdef CR8_G_ADD_75MS else if (frame_dms == 75) { factor = 1.2; } #endif else { factor = 1; } Loading Loading @@ -60,7 +70,7 @@ void processAdjustGlobalGain_fl(LC3_INT* gg_idx, LC3_INT gg_idx_min, LC3_INT gg_ if (hrmode) { if (nBits > target) { gg_idx_inc = (int) factor * (((nBits - target)/ delta) + 1); gg_idx_inc = (int) (factor * (((nBits - target)/ delta) + 1)); gg_idx_inc = MIN(gg_idx_inc, 10 * factor); *gg_idx += gg_idx_inc; Loading
lib_lc3plus/al_fec_fl.c +1 −1 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading
lib_lc3plus/apply_global_gain.c +2 −2 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading @@ -13,7 +13,7 @@ void processApplyGlobalGain_fl(LC3_FLOAT x[], LC3_INT xLen, LC3_INT global_gain_idx, LC3_INT global_gain_off) { LC3_FLOAT gg = 0; LC3_FLOAT gg; gg = LC3_POW(10, (LC3_FLOAT)(global_gain_idx + global_gain_off) / 28); Loading
lib_lc3plus/ari_codec.c +807 −154 File changed.Preview size limit exceeded, changes collapsed. Show changes
lib_lc3plus/attack_detector.c +12 −26 Original line number Diff line number Diff line /****************************************************************************** * ETSI TS 103 634 V1.4.1 * * ETSI TS 103 634 V1.4.3 * * Low Complexity Communication Codec Plus (LC3plus) * * * * Copyright licence is solely granted through ETSI Intellectual Property * Loading @@ -14,26 +14,19 @@ void attack_detector_fl(LC3_FLOAT* in, LC3_INT frame_size, LC3_INT fs, LC3_INT* lastAttackPosition, LC3_FLOAT* accNrg, LC3_INT* attackFlag, LC3_FLOAT* attdec_filter_mem, LC3_INT attackHandlingOn, LC3_INT attdec_nblocks, LC3_INT attdec_hangover_threshold) { LC3_FLOAT f_sig[160] = {0}, block_nrg[4] = {0}, sum = 0, tmpEne = 0, *ptr = NULL, tmp[162] = {0}; LC3_INT i = 0, j = 0, attackPosition = 0; LC3_FLOAT mval = 0; LC3_INT frame_size_16k = attdec_nblocks * 40; LC3_FLOAT f_sig[160], block_nrg[4], sum, tmpEne, *ptr, tmp[162]; LC3_INT i, j, attackPosition; LC3_FLOAT mval; LC3_INT frame_size_16k; if (attackHandlingOn) { mval = 0; j = 0; frame_size_16k = attdec_nblocks * 40; ptr = &tmp[2]; if (attackHandlingOn) { /* Decimate 96, 48 and 32 kHz signals to 16 kHz */ if (fs == 96000) { for (i = 0; i < frame_size;) { ptr[j] = in[i] + in[i + 1] + in[i + 2] + in[i + 3] + in[i + 4] + in[i + 5]; i = i + 6; j++; } mval = 1e-5; } else if (fs == 48000) { /* Decimate 48 and 32 kHz signals to 16 kHz */ if (fs == 48000) { j = 0; for (i = 0; i < frame_size;) { ptr[j] = (in[i] + in[i + 1] + in[i + 2]); Loading @@ -47,13 +40,6 @@ void attack_detector_fl(LC3_FLOAT* in, LC3_INT frame_size, LC3_INT fs, LC3_INT* i = i + 2; j++; } } else if (fs == 24000) { j = 0; for (i = 0; i < frame_size;) { ptr[j] = (in[i] + (in[i + 1] + in[i + 2]) / 2.0); i = i + 3; j++; } } /* Filter */ Loading