pkgsrc/audio/mpg123/patches/patch-ae
simonb b55ba7a0d1 Add fixed-point support used by the arm32.
XXX: Uses strongarm C-compiler options to use 32x32=64 int multiply.
1999-10-12 04:43:11 +00:00

16 lines
508 B
Text

$NetBSD: patch-ae,v 1.5 1999/10/12 04:43:13 simonb Exp $
--- dct64_i486.c.orig Thu Nov 19 21:42:36 1998
+++ dct64_i486.c Mon Aug 16 01:49:16 1999
@@ -47,7 +47,11 @@
#define SETOUT(out,n,expr) out[FIR_BUFFER_SIZE*(n)]=(expr)
#define MUL(a,b) (((a)*(b)) >> 15)
#define MULL(a,b) (((long long)(a)*(long long)(b)) >> 15)
+#ifdef REAL_IS_FIXED
+#define TOINT(a) ((a) * 32768 / (int)REAL_FACTOR)
+#else
#define TOINT(a) ((int)((a)*32768.0))
+#endif
void dct64_1_486(int *out0,int *out1,int *b1,int *b2)
{