1 /********************************************************************
3 * THIS FILE IS PART OF THE OggVorbis SOFTWARE CODEC SOURCE CODE. *
4 * USE, DISTRIBUTION AND REPRODUCTION OF THIS SOURCE IS GOVERNED BY *
5 * THE GNU LESSER/LIBRARY PUBLIC LICENSE, WHICH IS INCLUDED WITH *
6 * THIS SOURCE. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. *
8 * THE OggVorbis SOURCE CODE IS (C) COPYRIGHT 1994-2000 *
9 * by Monty <monty@xiph.org> and the XIPHOPHORUS Company *
10 * http://www.xiph.org/ *
12 ********************************************************************
14 function: modified discrete cosine transform prototypes
15 last mod: $Id: mdct.h,v 1.16 2000/12/21 21:04:39 xiphmont Exp $
17 ********************************************************************/
22 #include "vorbis/codec.h"
24 /*#define MDCT_INTEGERIZED <- be warned there could be some hurt left here*/
25 #ifdef MDCT_INTEGERIZED
28 #define REG_TYPE register int
34 #define FLOAT_CONV(x) ((int)((x)*(1<<TRIGBITS)+.5))
35 #define MULT_NORM(x) ((x)>>TRIGBITS)
36 #define HALVE(x) ((x)>>1)
40 #define DATA_TYPE float
41 #define REG_TYPE float
42 #define cPI3_8 .38268343236508977175F
43 #define cPI2_8 .70710678118654752441F
44 #define cPI1_8 .92387953251128675613F
46 #define FLOAT_CONV(x) (x)
47 #define MULT_NORM(x) (x)
48 #define HALVE(x) ((x)*.5f)
63 extern void mdct_init(mdct_lookup *lookup,int n);
64 extern void mdct_clear(mdct_lookup *l);
65 extern void mdct_forward(mdct_lookup *init, DATA_TYPE *in, DATA_TYPE *out);
66 extern void mdct_backward(mdct_lookup *init, DATA_TYPE *in, DATA_TYPE *out);