• Main Page
  • Related Pages
  • Modules
  • Data Structures
  • Files
  • Examples
  • File List
  • Globals

libavcodec/mpegaudiodsp.h

Go to the documentation of this file.
00001 /*
00002  * This file is part of Libav.
00003  *
00004  * Libav is free software; you can redistribute it and/or
00005  * modify it under the terms of the GNU Lesser General Public
00006  * License as published by the Free Software Foundation; either
00007  * version 2.1 of the License, or (at your option) any later version.
00008  *
00009  * Libav is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012  * Lesser General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU Lesser General Public
00015  * License along with Libav; if not, write to the Free Software
00016  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
00017  */
00018 
00019 #ifndef AVCODEC_MPEGAUDIODSP_H
00020 #define AVCODEC_MPEGAUDIODSP_H
00021 
00022 #include <stdint.h>
00023 #include "libavutil/common.h"
00024 
00025 typedef struct MPADSPContext {
00026     void (*apply_window_float)(float *synth_buf, float *window,
00027                                int *dither_state, float *samples, int incr);
00028     void (*apply_window_fixed)(int32_t *synth_buf, int32_t *window,
00029                                int *dither_state, int16_t *samples, int incr);
00030     void (*dct32_float)(float *dst, const float *src);
00031     void (*dct32_fixed)(int *dst, const int *src);
00032     void (*imdct36_blocks_float)(float *out, float *buf, float *in,
00033                                  int count, int switch_point, int block_type);
00034     void (*imdct36_blocks_fixed)(int *out, int *buf, int *in,
00035                                  int count, int switch_point, int block_type);
00036 } MPADSPContext;
00037 
00038 void ff_mpadsp_init(MPADSPContext *s);
00039 
00040 extern int32_t ff_mpa_synth_window_fixed[];
00041 extern float   ff_mpa_synth_window_float[];
00042 
00043 void ff_mpa_synth_filter_fixed(MPADSPContext *s,
00044                                int32_t *synth_buf_ptr, int *synth_buf_offset,
00045                                int32_t *window, int *dither_state,
00046                                int16_t *samples, int incr,
00047                                int32_t *sb_samples);
00048 
00049 void ff_mpa_synth_filter_float(MPADSPContext *s,
00050                                float *synth_buf_ptr, int *synth_buf_offset,
00051                                float *window, int *dither_state,
00052                                float *samples, int incr,
00053                                float *sb_samples);
00054 
00055 void ff_mpadsp_init_arm(MPADSPContext *s);
00056 void ff_mpadsp_init_mmx(MPADSPContext *s);
00057 void ff_mpadsp_init_altivec(MPADSPContext *s);
00058 
00059 void ff_mpa_synth_init_float(float *window);
00060 void ff_mpa_synth_init_fixed(int32_t *window);
00061 
00062 void ff_mpadsp_apply_window_float(float *synth_buf, float *window,
00063                                   int *dither_state, float *samples,
00064                                   int incr);
00065 void ff_mpadsp_apply_window_fixed(int32_t *synth_buf, int32_t *window,
00066                                   int *dither_state, int16_t *samples,
00067                                   int incr);
00068 
00069 void ff_imdct36_blocks_float(float *out, float *buf, float *in,
00070                              int count, int switch_point, int block_type);
00071 
00072 void ff_imdct36_blocks_fixed(int *out, int *buf, int *in,
00073                              int count, int switch_point, int block_type);
00074 
00075 void ff_init_mpadsp_tabs_float(void);
00076 void ff_init_mpadsp_tabs_fixed(void);
00077 
00079 #define MDCT_BUF_SIZE FFALIGN(36, 2*4)
00080 
00081 extern int ff_mdct_win_fixed[8][MDCT_BUF_SIZE];
00082 extern float ff_mdct_win_float[8][MDCT_BUF_SIZE];
00083 
00084 #endif /* AVCODEC_MPEGAUDIODSP_H */
Generated on Sun Apr 22 2012 21:54:02 for Libav by doxygen 1.7.1