Home | History | Annotate | Download | only in source
      1 /*
      2  *  Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
      3  *
      4  *  Use of this source code is governed by a BSD-style license
      5  *  that can be found in the LICENSE file in the root of the source
      6  *  tree. An additional intellectual property rights grant can be found
      7  *  in the file PATENTS.  All contributing project authors may
      8  *  be found in the AUTHORS file in the root of the source tree.
      9  */
     10 
     11 #ifndef WEBRTC_MODULES_AUDIO_CODING_CODECS_ISAC_FIX_SOURCE_FILTERBANK_INTERNAL_H_
     12 #define WEBRTC_MODULES_AUDIO_CODING_CODECS_ISAC_FIX_SOURCE_FILTERBANK_INTERNAL_H_
     13 
     14 #include "webrtc/typedefs.h"
     15 
     16 #if defined(__cplusplus) || defined(c_plusplus)
     17 extern "C" {
     18 #endif
     19 
     20 /* Arguments:
     21  *   io:  Input/output, in Q0.
     22  *   len: Input, sample length.
     23  *   coefficient: Input.
     24  *   state: Input/output, filter state, in Q4.
     25  */
     26 typedef void (*HighpassFilterFixDec32)(int16_t* io,
     27                                        int16_t len,
     28                                        const int16_t* coefficient,
     29                                        int32_t* state);
     30 extern HighpassFilterFixDec32 WebRtcIsacfix_HighpassFilterFixDec32;
     31 
     32 void WebRtcIsacfix_HighpassFilterFixDec32C(int16_t* io,
     33                                            int16_t len,
     34                                            const int16_t* coefficient,
     35                                            int32_t* state);
     36 
     37 #if defined(MIPS_DSP_R1_LE)
     38 void WebRtcIsacfix_HighpassFilterFixDec32MIPS(int16_t* io,
     39                                               int16_t len,
     40                                               const int16_t* coefficient,
     41                                               int32_t* state);
     42 #endif
     43 
     44 typedef void (*AllpassFilter2FixDec16)(
     45     int16_t *data_ch1,           // Input and output in channel 1, in Q0
     46     int16_t *data_ch2,           // Input and output in channel 2, in Q0
     47     const int16_t *factor_ch1,   // Scaling factor for channel 1, in Q15
     48     const int16_t *factor_ch2,   // Scaling factor for channel 2, in Q15
     49     const int length,            // Length of the data buffers
     50     int32_t *filter_state_ch1,   // Filter state for channel 1, in Q16
     51     int32_t *filter_state_ch2);  // Filter state for channel 2, in Q16
     52 extern AllpassFilter2FixDec16 WebRtcIsacfix_AllpassFilter2FixDec16;
     53 
     54 void WebRtcIsacfix_AllpassFilter2FixDec16C(
     55    int16_t *data_ch1,
     56    int16_t *data_ch2,
     57    const int16_t *factor_ch1,
     58    const int16_t *factor_ch2,
     59    const int length,
     60    int32_t *filter_state_ch1,
     61    int32_t *filter_state_ch2);
     62 
     63 #if (defined WEBRTC_DETECT_NEON) || (defined WEBRTC_HAS_NEON)
     64 void WebRtcIsacfix_AllpassFilter2FixDec16Neon(
     65    int16_t *data_ch1,
     66    int16_t *data_ch2,
     67    const int16_t *factor_ch1,
     68    const int16_t *factor_ch2,
     69    const int length,
     70    int32_t *filter_state_ch1,
     71    int32_t *filter_state_ch2);
     72 #endif
     73 
     74 #if defined(MIPS_DSP_R1_LE)
     75 void WebRtcIsacfix_AllpassFilter2FixDec16MIPS(
     76    int16_t *data_ch1,
     77    int16_t *data_ch2,
     78    const int16_t *factor_ch1,
     79    const int16_t *factor_ch2,
     80    const int length,
     81    int32_t *filter_state_ch1,
     82    int32_t *filter_state_ch2);
     83 #endif
     84 
     85 #if defined(__cplusplus) || defined(c_plusplus)
     86 }
     87 #endif
     88 
     89 #endif
     90 /* WEBRTC_MODULES_AUDIO_CODING_CODECS_ISAC_FIX_SOURCE_FILTERBANK_INTERNAL_H_ */
     91