]> git.sesse.net Git - ffmpeg/blob - libavcodec/sbrdsp.h
ff_alloc_packet: modify the size of the packet to match the requested size
[ffmpeg] / libavcodec / sbrdsp.h
1 /*
2  * Copyright (c) 2012 Mans Rullgard
3  *
4  * This file is part of Libav.
5  *
6  * Libav is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * Libav is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with Libav; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19  */
20
21 #ifndef LIBAVCODEC_SBRDSP_H
22 #define LIBAVCODEC_SBRDSP_H
23
24 typedef struct SBRDSPContext {
25     void (*sum64x5)(float *z);
26     float (*sum_square)(float (*x)[2], int n);
27     void (*neg_odd_64)(float *x);
28     void (*qmf_pre_shuffle)(float *z);
29     void (*qmf_post_shuffle)(float W[32][2], const float *z);
30     void (*qmf_deint_neg)(float *v, const float *src);
31     void (*qmf_deint_bfly)(float *v, const float *src0, const float *src1);
32     void (*autocorrelate)(const float x[40][2], float phi[3][2][2]);
33     void (*hf_gen)(float (*X_high)[2], const float (*X_low)[2],
34                    const float alpha0[2], const float alpha1[2],
35                    float bw, int start, int end);
36     void (*hf_g_filt)(float (*Y)[2], const float (*X_high)[40][2],
37                       const float *g_filt, int m_max, int ixh);
38     void (*hf_apply_noise[4])(float (*Y)[2], const float *s_m,
39                               const float *q_filt, int noise,
40                               int kx, int m_max);
41 } SBRDSPContext;
42
43 extern const float ff_sbr_noise_table[][2];
44
45 void ff_sbrdsp_init(SBRDSPContext *s);
46 void ff_sbrdsp_init_arm(SBRDSPContext *s);
47
48 #endif