libavcodec/aacpsdsp.h
bf1945af
 /*
  * Copyright (c) 2012 Mans Rullgard
  *
d814a839
  * This file is part of FFmpeg.
bf1945af
  *
d814a839
  * FFmpeg is free software; you can redistribute it and/or
bf1945af
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
  *
d814a839
  * FFmpeg is distributed in the hope that it will be useful,
bf1945af
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
  *
  * You should have received a copy of the GNU Lesser General Public
d814a839
  * License along with FFmpeg; if not, write to the Free Software
bf1945af
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
 #ifndef LIBAVCODEC_AACPSDSP_H
 #define LIBAVCODEC_AACPSDSP_H
 
5fd81cf6
 #include "aac_defines.h"
 
bf1945af
 #define PS_QMF_TIME_SLOTS 32
 #define PS_AP_LINKS 3
 #define PS_MAX_AP_DELAY 5
 
 typedef struct PSDSPContext {
5fd81cf6
     void (*add_squares)(INTFLOAT *dst, const INTFLOAT (*src)[2], int n);
     void (*mul_pair_single)(INTFLOAT (*dst)[2], INTFLOAT (*src0)[2], INTFLOAT *src1,
bf1945af
                             int n);
5fd81cf6
     void (*hybrid_analysis)(INTFLOAT (*out)[2], INTFLOAT (*in)[2],
                             const INTFLOAT (*filter)[8][2],
bf1945af
                             int stride, int n);
5fd81cf6
     void (*hybrid_analysis_ileave)(INTFLOAT (*out)[32][2], INTFLOAT L[2][38][64],
bf1945af
                                    int i, int len);
5fd81cf6
     void (*hybrid_synthesis_deint)(INTFLOAT out[2][38][64], INTFLOAT (*in)[32][2],
bf1945af
                                    int i, int len);
5fd81cf6
     void (*decorrelate)(INTFLOAT (*out)[2], INTFLOAT (*delay)[2],
                         INTFLOAT (*ap_delay)[PS_QMF_TIME_SLOTS+PS_MAX_AP_DELAY][2],
                         const INTFLOAT phi_fract[2], const INTFLOAT (*Q_fract)[2],
                         const INTFLOAT *transient_gain,
                         INTFLOAT g_decay_slope,
bf1945af
                         int len);
5fd81cf6
     void (*stereo_interpolate[2])(INTFLOAT (*l)[2], INTFLOAT (*r)[2],
                                   INTFLOAT h[2][4], INTFLOAT h_step[2][4],
bf1945af
                                   int len);
 } PSDSPContext;
 
5fd81cf6
 void AAC_RENAME(ff_psdsp_init)(PSDSPContext *s);
96f7590e
 void ff_psdsp_init_arm(PSDSPContext *s);
46d52a0b
 void ff_psdsp_init_mips(PSDSPContext *s);
9dcaae70
 void ff_psdsp_init_x86(PSDSPContext *s);
bf1945af
 
 #endif /* LIBAVCODEC_AACPSDSP_H */