Libav 0.7.1
|
00001 /* 00002 * Copyright (c) 2009 Mans Rullgard <mans@mansr.com> 00003 * 00004 * This file is part of Libav. 00005 * 00006 * Libav is free software; you can redistribute it and/or 00007 * modify it under the terms of the GNU Lesser General Public 00008 * License as published by the Free Software Foundation; either 00009 * version 2.1 of the License, or (at your option) any later version. 00010 * 00011 * Libav is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00014 * Lesser General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU Lesser General Public 00017 * License along with Libav; if not, write to the Free Software 00018 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00019 */ 00020 00021 #include "libavcodec/fft.h" 00022 #include "libavcodec/rdft.h" 00023 #include "libavcodec/synth_filter.h" 00024 00025 void ff_fft_permute_neon(FFTContext *s, FFTComplex *z); 00026 void ff_fft_calc_neon(FFTContext *s, FFTComplex *z); 00027 00028 void ff_imdct_calc_neon(FFTContext *s, FFTSample *output, const FFTSample *input); 00029 void ff_imdct_half_neon(FFTContext *s, FFTSample *output, const FFTSample *input); 00030 void ff_mdct_calc_neon(FFTContext *s, FFTSample *output, const FFTSample *input); 00031 00032 void ff_rdft_calc_neon(struct RDFTContext *s, FFTSample *z); 00033 00034 void ff_synth_filter_float_neon(FFTContext *imdct, 00035 float *synth_buf_ptr, int *synth_buf_offset, 00036 float synth_buf2[32], const float window[512], 00037 float out[32], const float in[32], 00038 float scale); 00039 00040 av_cold void ff_fft_init_arm(FFTContext *s) 00041 { 00042 if (HAVE_NEON) { 00043 s->fft_permute = ff_fft_permute_neon; 00044 s->fft_calc = ff_fft_calc_neon; 00045 s->imdct_calc = ff_imdct_calc_neon; 00046 s->imdct_half = ff_imdct_half_neon; 00047 s->mdct_calc = ff_mdct_calc_neon; 00048 s->mdct_permutation = FF_MDCT_PERM_INTERLEAVE; 00049 } 00050 } 00051 00052 #if CONFIG_RDFT 00053 av_cold void ff_rdft_init_arm(RDFTContext *s) 00054 { 00055 if (HAVE_NEON) 00056 s->rdft_calc = ff_rdft_calc_neon; 00057 } 00058 #endif 00059 00060 #if CONFIG_DCA_DECODER 00061 av_cold void ff_synth_filter_init_arm(SynthFilterContext *s) 00062 { 00063 if (HAVE_NEON) 00064 s->synth_filter_float = ff_synth_filter_float_neon; 00065 } 00066 #endif