1
/* SoX Resampler Library Copyright (c) 2007-13 robs@users.sourceforge.net
2
* Licence for this file: LGPL v2.1 See LICENCE for details. */
4
/* Common includes etc. for the examples. */
16
/* Work-around for broken file-I/O on MS-Windows: */
19
#define USE_STD_STDIO _setmode(_fileno(stdout), _O_BINARY), \
20
_setmode(_fileno(stdin ), _O_BINARY);
21
/* Sometimes missing, so ensure that it is defined: */
23
#define M_PI 3.14159265358979323846
32
#if LONG_MAX > 2147483647L
34
#elif LONG_MAX < 2147483647L
35
#error this programme requires that 'long int' has at least 32-bits
42
#define min(x,y) ((x)<(y)?(x):(y))
43
#define max(x,y) ((x)>(y)?(x):(y))
45
#define AL(a) (sizeof(a)/sizeof((a)[0])) /* Array Length */