1 /* Copyright (C) 2005 Psi Systems, Inc. 2 File: config.h 3 Main Speex option include file for TI C64xx, C54xx and C55xx processors 4 for use with TI Code Composer (TM) DSP development tools. 5 6 Redistribution and use in source and binary forms, with or without 7 modification, are permitted provided that the following conditions 8 are met: 9 10 - Redistributions of source code must retain the above copyright 11 notice, this list of conditions and the following disclaimer. 12 13 - Redistributions in binary form must reproduce the above copyright 14 notice, this list of conditions and the following disclaimer in the 15 documentation and/or other materials provided with the distribution. 16 17 - Neither the name of the Xiph.org Foundation nor the names of its 18 contributors may be used to endorse or promote products derived from 19 this software without specific prior written permission. 20 21 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 24 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR 25 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 26 EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 27 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 28 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 29 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 30 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 31 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 34 #define FIXED_POINT 35 #define FRAME_SIZE 160 36 #define DISABLE_WIDEBAND 37 #define EXPORT 38 39 /* Disable DC block if doing SNR testing */ 40 #define DISABLE_HIGHPASS 41 42 /* Allow for 2 20ms narrowband blocks per frame, plus a couple of bytes */ 43 #define MAX_CHARS_PER_FRAME (42/BYTES_PER_CHAR) 44 45 /* for debug */ 46 #undef DECODE_ONLY 47 #define VERBOSE_ALLOC 48 49 /* EITHER Allocate from fixed array (C heap not used) */ 50 /* Enable VERBOSE_ALLOC to see how much is used */ 51 #define MANUAL_ALLOC 52 #define OS_SUPPORT_CUSTOM 53 54 /* OR Use CALLOC (heap size must be increased in linker command file) */ 55 //#undef MANUAL_ALLOC 56 //#undef OS_SUPPORT_CUSTOM 57 58 #if defined (CONFIG_TI_C54X) || defined (CONFIG_TI_C55X) 59 //#define PRECISION16 60 61 // These values determined by analysis for 8kbps narrowband 62 #define SPEEXENC_PERSIST_STACK_SIZE 1000 63 #define SPEEXENC_SCRATCH_STACK_SIZE 3000 64 #define SPEEXDEC_PERSIST_STACK_SIZE 1000 65 #define SPEEXDEC_SCRATCH_STACK_SIZE 1000 66 #else /* C6X */ 67 #define NO_LONGLONG 68 69 #define SPEEXENC_PERSIST_STACK_SIZE 2000 70 #define SPEEXENC_SCRATCH_STACK_SIZE 6000 71 #define SPEEXDEC_PERSIST_STACK_SIZE 2000 72 #define SPEEXDEC_SCRATCH_STACK_SIZE 2000 73 #endif 74 #define SPEEX_PERSIST_STACK_SIZE (SPEEXENC_PERSIST_STACK_SIZE + SPEEXDEC_PERSIST_STACK_SIZE) 75 #define SPEEX_SCRATCH_STACK_SIZE SPEEXENC_SCRATCH_STACK_SIZE 76 #define NB_ENC_STACK SPEEXENC_SCRATCH_STACK_SIZE 77 #define NB_DEC_STACK SPEEXDEC_SCRATCH_STACK_SIZE 78 79