forked from len0rd/rockbox
opus: #if 0 out some more unused code, delete unused file
Change-Id: I96033f42e0c3096ec9d779e9f8ca46570f981ab0
This commit is contained in:
parent
f498142143
commit
06fc6fdd0a
8 changed files with 16 additions and 47 deletions
|
@ -31,7 +31,6 @@ silk/decode_pulses.c
|
|||
silk/decoder_set_fs.c
|
||||
silk/gain_quant.c
|
||||
silk/init_decoder.c
|
||||
silk/lin2log.c
|
||||
silk/log2lin.c
|
||||
silk/LPC_analysis_filter.c
|
||||
silk/LPC_inv_pred_gain.c
|
||||
|
|
|
@ -132,6 +132,7 @@ opus_int32 silk_LPC_inverse_pred_gain( /* O Returns inverse predi
|
|||
|
||||
#ifdef FIXED_POINT
|
||||
|
||||
#if 0
|
||||
/* For input in Q24 domain */
|
||||
opus_int32 silk_LPC_inverse_pred_gain_Q24( /* O Returns inverse prediction gain in energy domain, Q30 */
|
||||
const opus_int32 *A_Q24, /* I Prediction coefficients [order] */
|
||||
|
@ -152,3 +153,4 @@ opus_int32 silk_LPC_inverse_pred_gain_Q24( /* O Returns inverse pred
|
|||
return LPC_inverse_pred_gain_QA( Atmp_QA, order );
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -151,11 +151,13 @@ void silk_ana_filt_bank_1(
|
|||
/* SCALAR FUNCTIONS */
|
||||
/********************************************************************/
|
||||
|
||||
#if 0
|
||||
/* Approximation of 128 * log2() (exact inverse of approx 2^() below) */
|
||||
/* Convert input to a log scale */
|
||||
opus_int32 silk_lin2log(
|
||||
const opus_int32 inLin /* I input in linear scale */
|
||||
);
|
||||
#endif
|
||||
|
||||
/* Approximation of a sigmoid function */
|
||||
opus_int silk_sigm_Q15(
|
||||
|
|
|
@ -37,6 +37,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
#define silk_enc_map(a) ( silk_RSHIFT( (a), 15 ) + 1 )
|
||||
#define silk_dec_map(a) ( silk_LSHIFT( (a), 1 ) - 1 )
|
||||
|
||||
#if 0
|
||||
/* Encodes signs of excitation */
|
||||
void silk_encode_signs(
|
||||
ec_enc *psRangeEnc, /* I/O Compressor data structure */
|
||||
|
@ -70,6 +71,7 @@ void silk_encode_signs(
|
|||
q_ptr += SHELL_CODEC_FRAME_LENGTH;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Decodes signs of excitation */
|
||||
void silk_decode_signs(
|
||||
|
|
|
@ -35,6 +35,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
#define SCALE_Q16 ( ( 65536 * ( N_LEVELS_QGAIN - 1 ) ) / ( ( ( MAX_QGAIN_DB - MIN_QGAIN_DB ) * 128 ) / 6 ) )
|
||||
#define INV_SCALE_Q16 ( ( 65536 * ( ( ( MAX_QGAIN_DB - MIN_QGAIN_DB ) * 128 ) / 6 ) ) / ( N_LEVELS_QGAIN - 1 ) )
|
||||
|
||||
#if 0
|
||||
/* Gain scalar quantization with hysteresis, uniform on log scale */
|
||||
void silk_gains_quant(
|
||||
opus_int8 ind[ MAX_NB_SUBFR ], /* O gain indices */
|
||||
|
@ -88,6 +89,7 @@ void silk_gains_quant(
|
|||
gain_Q16[ k ] = silk_log2lin( silk_min_32( silk_SMULWB( INV_SCALE_Q16, *prev_ind ) + OFFSET, 3967 ) ); /* 3967 = 31 in Q7 */
|
||||
}
|
||||
}
|
||||
# endif
|
||||
|
||||
/* Gains scalar dequantization, uniform on log scale */
|
||||
void silk_gains_dequant(
|
||||
|
@ -123,6 +125,7 @@ void silk_gains_dequant(
|
|||
}
|
||||
}
|
||||
|
||||
#if 0
|
||||
/* Compute unique identifier of gain indices vector */
|
||||
opus_int32 silk_gains_ID( /* O returns unique identifier of gains */
|
||||
const opus_int8 ind[ MAX_NB_SUBFR ], /* I gain indices */
|
||||
|
@ -139,3 +142,4 @@ opus_int32 silk_gains_ID( /* O returns
|
|||
|
||||
return gainsID;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -1,46 +0,0 @@
|
|||
/***********************************************************************
|
||||
Copyright (c) 2006-2011, Skype Limited. All rights reserved.
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
- Redistributions of source code must retain the above copyright notice,
|
||||
this list of conditions and the following disclaimer.
|
||||
- Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
- Neither the name of Internet Society, IETF or IETF Trust, nor the
|
||||
names of specific contributors, may be used to endorse or promote
|
||||
products derived from this software without specific prior written
|
||||
permission.
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS”
|
||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGE.
|
||||
***********************************************************************/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "opus_config.h"
|
||||
#endif
|
||||
|
||||
#include "SigProc_FIX.h"
|
||||
/* Approximation of 128 * log2() (very close inverse of silk_log2lin()) */
|
||||
/* Convert input to a log scale */
|
||||
opus_int32 silk_lin2log(
|
||||
const opus_int32 inLin /* I input in linear scale */
|
||||
)
|
||||
{
|
||||
opus_int32 lz, frac_Q7;
|
||||
|
||||
silk_CLZ_FRAC( inLin, &lz, &frac_Q7 );
|
||||
|
||||
/* Piece-wise parabolic approximation */
|
||||
return silk_LSHIFT( 31 - lz, 7 ) + silk_SMLAWB( frac_Q7, silk_MUL( frac_Q7, 128 - frac_Q7 ), 179 );
|
||||
}
|
||||
|
|
@ -45,6 +45,7 @@ static inline void combine_pulses(
|
|||
}
|
||||
}
|
||||
|
||||
#if 0
|
||||
static inline void encode_split(
|
||||
ec_enc *psRangeEnc, /* I/O compressor data structure */
|
||||
const opus_int p_child1, /* I pulse amplitude of first child subframe */
|
||||
|
@ -56,6 +57,7 @@ static inline void encode_split(
|
|||
ec_enc_icdf( psRangeEnc, p_child1, &shell_table[ silk_shell_code_table_offsets[ p ] ], 8 );
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void decode_split(
|
||||
opus_int *p_child1, /* O pulse amplitude of first child subframe */
|
||||
|
@ -74,6 +76,7 @@ static inline void decode_split(
|
|||
}
|
||||
}
|
||||
|
||||
#if 0
|
||||
/* Shell encoder, operates on one shell code frame of 16 pulses */
|
||||
void silk_shell_encoder(
|
||||
ec_enc *psRangeEnc, /* I/O compressor data structure */
|
||||
|
@ -113,6 +116,7 @@ void silk_shell_encoder(
|
|||
encode_split( psRangeEnc, pulses0[ 12 ], pulses1[ 6 ], silk_shell_code_table0 );
|
||||
encode_split( psRangeEnc, pulses0[ 14 ], pulses1[ 7 ], silk_shell_code_table0 );
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
/* Shell decoder, operates on one shell code frame of 16 pulses */
|
||||
|
|
|
@ -37,6 +37,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
#include "SigProc_FIX.h"
|
||||
|
||||
#if 0
|
||||
void silk_insertion_sort_increasing(
|
||||
opus_int32 *a, /* I/O Unsorted / Sorted vector */
|
||||
opus_int *idx, /* O Index vector for the sorted elements */
|
||||
|
@ -131,6 +132,7 @@ void silk_insertion_sort_decreasing_int16(
|
|||
}
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
void silk_insertion_sort_increasing_all_values_int16(
|
||||
opus_int16 *a, /* I/O Unsorted / Sorted vector */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue