1 /******************************************************************************
2  *                                                                            *
3  * Copyright (C) 2018 The Android Open Source Project
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at:
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *****************************************************************************
18  * Originally developed and contributed by Ittiam Systems Pvt. Ltd, Bangalore
19 */
20 #ifndef IXHEAACD_ENV_DEC_H
21 #define IXHEAACD_ENV_DEC_H
22 
23 VOID ixheaacd_dec_sbrdata(ia_sbr_header_data_struct *ptr_header_data_ch_0,
24                           ia_sbr_header_data_struct *ptr_header_data_ch_1,
25                           ia_sbr_frame_info_data_struct *ptr_sbr_data_ch_0,
26                           ia_sbr_prev_frame_data_struct *ptr_prev_data_ch_0,
27                           ia_sbr_frame_info_data_struct *ptr_sbr_data_ch_1,
28                           ia_sbr_prev_frame_data_struct *ptr_prev_data_ch_1,
29                           ixheaacd_misc_tables *ptr_common_tables);
30 
31 VOID ixheaacd_dec_sbrdata_for_pvc(ia_sbr_header_data_struct *ptr_header_data,
32                                   ia_sbr_frame_info_data_struct *ptr_sbr_data,
33                                   ia_sbr_prev_frame_data_struct *ptr_prev_data);
34 
35 VOID ixheaacd_harm_idx_onethreelp(WORD32 *ptr_real_buf, WORD16 *ptr_gain_buf,
36                                   WORD scale_change, WORD16 *ptr_sine_level_buf,
37                                   const WORD32 *ptr_rand_ph,
38                                   WORD16 *noise_lvl_me, WORD num_subband,
39                                   FLAG noise_absc_flag, WORD freq_inv_flag,
40                                   WORD noise_e, WORD sub_band_start);
41 
42 VOID ixheaacd_harm_idx_zerotwo(FLAG noise_absc_flag, WORD16 num_subband,
43                                WORD32 *ptr_real_buf, WORD32 *ptr_im,
44                                WORD16 *smoothed_gain, WORD16 *smoothed_noise,
45                                WORD factor, WORD16 *ptr_gain_buf,
46                                WORD16 scale_change, const WORD32 *ptr_rand_ph,
47                                WORD16 *ptr_sine_level_buf, WORD16 noise_e,
48                                WORD32 harm_index);
49 
50 VOID ixheaacd_harm_idx_onethree(FLAG noise_absc_flag, WORD16 num_subband,
51                                 WORD32 *ptr_real_buf, WORD32 *ptr_im,
52                                 WORD16 *smoothed_gain, WORD16 *smoothed_noise,
53                                 WORD factor, WORD16 *ptr_gain_buf,
54                                 WORD16 scale_change, const WORD32 *ptr_rand_ph,
55                                 WORD16 *ptr_sine_level_buf, WORD16 noise_e,
56                                 WORD freq_inv_flag, WORD32 harm_index);
57 
58 VOID ixheaacd_dec_envelope(ia_sbr_header_data_struct *ptr_header_data,
59                            ia_sbr_frame_info_data_struct *ptr_sbr_data,
60                            ia_sbr_prev_frame_data_struct *ptr_prev_data,
61                            ia_sbr_prev_frame_data_struct *ptr_prev_data_ch_1,
62                            ixheaacd_misc_tables *pstr_common_tables);
63 
64 VOID ixheaacd_lean_sbrconcealment(ia_sbr_header_data_struct *ptr_header_data,
65                                   ia_sbr_frame_info_data_struct *ptr_sbr_data,
66                                   ia_sbr_prev_frame_data_struct *ptr_prev_data);
67 
68 #endif
69