diff options
author | Marcoen Hirschberg <marcoen@gmail.com> | 2007-10-01 13:46:07 +0000 |
---|---|---|
committer | Marcoen Hirschberg <marcoen@gmail.com> | 2007-10-01 13:46:07 +0000 |
commit | b8753ffdaa141740e42d8c57d6f0c1aca5e6a8de (patch) | |
tree | d912174b68dda4378addd1c4aeb733a86e97af4b /apps/codecs | |
parent | 6b559b21886d4da8b59bb4fe11dddb2835f31180 (diff) |
move structures around in the header files
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14941 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs')
-rw-r--r-- | apps/codecs/libwma/fft.c | 3 | ||||
-rw-r--r-- | apps/codecs/libwma/fft.h | 21 | ||||
-rw-r--r-- | apps/codecs/libwma/mdct.c | 4 | ||||
-rw-r--r-- | apps/codecs/libwma/mdct.h | 12 | ||||
-rw-r--r-- | apps/codecs/libwma/types.h | 5 | ||||
-rw-r--r-- | apps/codecs/libwma/wmadec.h | 35 | ||||
-rw-r--r-- | apps/codecs/libwma/wmadeci.c | 1 | ||||
-rw-r--r-- | apps/codecs/libwma/wmafixed.h | 1 |
8 files changed, 44 insertions, 38 deletions
diff --git a/apps/codecs/libwma/fft.c b/apps/codecs/libwma/fft.c index e934e3c1ce..f19dac0aed 100644 --- a/apps/codecs/libwma/fft.c +++ b/apps/codecs/libwma/fft.c @@ -17,7 +17,8 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "wmadec.h" +//#include "types.h" +#include "fft.h" #include "wmafixed.h" FFTComplex exptab0[512] IBSS_ATTR; diff --git a/apps/codecs/libwma/fft.h b/apps/codecs/libwma/fft.h index 2342140ef4..f3aaf2fcc8 100644 --- a/apps/codecs/libwma/fft.h +++ b/apps/codecs/libwma/fft.h @@ -17,6 +17,27 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +#include "types.h" + +typedef fixed32 FFTSample; + +typedef struct FFTComplex +{ + fixed32 re, im; +} +FFTComplex; + +typedef struct FFTContext +{ + int nbits; + int inverse; + uint16_t *revtab; + FFTComplex *exptab; + FFTComplex *exptab1; /* only used by SSE code */ + int (*fft_calc)(struct FFTContext *s, FFTComplex *z); +} +FFTContext; + int fft_calc_unscaled(FFTContext *s, FFTComplex *z); int fft_init_global(void); diff --git a/apps/codecs/libwma/mdct.c b/apps/codecs/libwma/mdct.c index 838bda47a7..e66be0e825 100644 --- a/apps/codecs/libwma/mdct.c +++ b/apps/codecs/libwma/mdct.c @@ -17,10 +17,8 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include <codecs/lib/codeclib.h> -#include "wmadec.h" #include "wmafixed.h" -#include "fft.h" +#include "mdct.h" fixed32 tcos0[1024], tsin0[1024]; //these are the sin and cos rotations used by the MDCT uint16_t revtab0[1024]; diff --git a/apps/codecs/libwma/mdct.h b/apps/codecs/libwma/mdct.h index bfa279b199..67f510164b 100644 --- a/apps/codecs/libwma/mdct.h +++ b/apps/codecs/libwma/mdct.h @@ -17,6 +17,18 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +//#include "types.h" +#include "fft.h" + +typedef struct MDCTContext +{ + int n; /* size of MDCT (i.e. number of input data * 2) */ + int nbits; /* n = 2^nbits */ + /* pre/post rotation tables */ + FFTContext fft; +} +MDCTContext; + int ff_mdct_init(MDCTContext *s, int nbits, int inverse); void ff_imdct_calc(MDCTContext *s, fixed32 *output, fixed32 *input); int mdct_init_global(void); diff --git a/apps/codecs/libwma/types.h b/apps/codecs/libwma/types.h index e69de29bb2..8a5e2a992e 100644 --- a/apps/codecs/libwma/types.h +++ b/apps/codecs/libwma/types.h @@ -0,0 +1,5 @@ +#include <codecs/lib/codeclib.h> + +#define fixed32 int32_t +#define fixed64 int64_t + diff --git a/apps/codecs/libwma/wmadec.h b/apps/codecs/libwma/wmadec.h index 1d5a67d8a9..f7434ed759 100644 --- a/apps/codecs/libwma/wmadec.h +++ b/apps/codecs/libwma/wmadec.h @@ -22,6 +22,8 @@ #include "asf.h" #include "bitstream.h" /* For GetBitContext */ +#include "types.h" +#include "mdct.h" //#include "dsputil.h" /* For MDCTContext */ @@ -52,39 +54,6 @@ #define LSP_POW_BITS 7 -#define fixed32 int32_t -#define fixed64 int64_t - -typedef fixed32 FFTSample; - -typedef struct FFTComplex -{ - fixed32 re, im; -} -FFTComplex; - -typedef struct FFTContext -{ - int nbits; - int inverse; - uint16_t *revtab; - FFTComplex *exptab; - FFTComplex *exptab1; /* only used by SSE code */ - int (*fft_calc)(struct FFTContext *s, FFTComplex *z); -} -FFTContext; - -typedef struct MDCTContext -{ - int n; /* size of MDCT (i.e. number of input data * 2) */ - int nbits; /* n = 2^nbits */ - /* pre/post rotation tables */ - fixed32 *tcos; - fixed32 *tsin; - FFTContext fft; -} -MDCTContext; - typedef struct WMADecodeContext { GetBitContext gb; diff --git a/apps/codecs/libwma/wmadeci.c b/apps/codecs/libwma/wmadeci.c index 8523beafbf..8b4c698ebc 100644 --- a/apps/codecs/libwma/wmadeci.c +++ b/apps/codecs/libwma/wmadeci.c @@ -28,7 +28,6 @@ #include "wmadec.h" #include "wmafixed.h" #include "bitstream.h" -#include "mdct.h" #define VLCBITS 7 /*7 is the lowest without glitching*/ diff --git a/apps/codecs/libwma/wmafixed.h b/apps/codecs/libwma/wmafixed.h index 8db1014a52..32386dc9bd 100644 --- a/apps/codecs/libwma/wmafixed.h +++ b/apps/codecs/libwma/wmafixed.h @@ -7,6 +7,7 @@ */ +#include "types.h" #define PRECISION 16 #define PRECISION64 16 |