annotate libfaad2/local_changes.diff @ 16390:1a0c19af8c7f

synced with 1.1087
author gpoirier
date Sun, 04 Sep 2005 21:48:51 +0000
parents d47cd711f617
children d89bfef62e03
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
1 --- libfaad/bits.h 2004-03-11 14:32:39.000000000 +0100
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
2 +++ libfaad2/bits.h 2004-06-24 10:47:02.000000000 +0200
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
3 @@ -58,7 +61,7 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
4
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
5 #if defined (_WIN32) && !defined(_WIN32_WCE) && !defined(__MINGW32__)
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
6 #define BSWAP(a) __asm mov eax,a __asm bswap eax __asm mov a, eax
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
7 -#elif defined(LINUX) || defined(DJGPP) || defined(__MINGW32__)
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
8 +#elif defined(LINUX) || defined(DJGPP)
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
9 #define BSWAP(a) __asm__ ( "bswapl %0\n" : "=r" (a) : "0" (a) )
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
10 #else
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
11 #define BSWAP(a) \
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
12 --- libfaad/common.h 2004-06-30 14:45:56.000000000 +0200
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
13 +++ libfaad2/common.h 2004-10-19 03:16:03.000000000 +0200
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
14 @@ -32,10 +35,13 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
15 extern "C" {
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
16 #endif
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
17
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
18 -#ifdef HAVE_CONFIG_H
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
19 -# include "../config.h"
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
20 +/* Allow build on Cygwin*/
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
21 +#if defined(__CYGWIN__)
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
22 +#define __STRICT_ANSI__
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
23 #endif
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
24
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
25 +#include "../config.h"
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
26 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
27 #define INLINE __inline
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
28 #if 0 //defined(_WIN32) && !defined(_WIN32_WCE)
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
29 #define ALIGN __declspec(align(16))
16249
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
30 @@ -67,6 +67,6 @@
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
31 /* Use if target platform has address generators with autoincrement */
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
32 //#define PREFER_POINTERS
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
33
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
34 -#ifdef _WIN32_WCE
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
35 +#if defined(_WIN32_WCE) || defined(__arm__)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
36 #define FIXED_POINT
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
37 #endif
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
38 @@ -117,6 +123,9 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
39 # ifdef MAIN_DEC
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
40 # undef MAIN_DEC
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
41 # endif
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
42 +# ifdef SBR_DEC
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
43 +# undef SBR_DEC
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
44 +# endif
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
45 #endif // FIXED_POINT
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
46
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
47 #ifdef DRM
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
48 @@ -157,6 +166,7 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
49
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
50 #include <stdlib.h>
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
51
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
52 +#if 0
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
53 typedef unsigned __int64 uint64_t;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
54 typedef unsigned __int32 uint32_t;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
55 typedef unsigned __int16 uint16_t;
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
56 @@ -165,11 +175,31 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
57 typedef __int32 int32_t;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
58 typedef __int16 int16_t;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
59 typedef __int8 int8_t;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
60 +#else
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
61 +#include <inttypes.h>
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
62 +#endif
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
63 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
64 typedef float float32_t;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
65
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
66
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
67 #else
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
68
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
69 +/* #undef HAVE_FLOAT32_T */
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
70 +/* Define if you have the <inttypes.h> header file. */
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
71 +#define HAVE_INTTYPES_H 1
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
72 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
73 +/* Define if you have the `memcpy' function. */
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
74 +#define HAVE_MEMCPY 1
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
75 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
76 +/* Define if you have the <stdint.h> header file. */
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
77 +#define HAVE_STDINT_H 1
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
78 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
79 +/* Define if you have the `strchr' function. */
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
80 +#define HAVE_STRCHR 1
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
81 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
82 +/* Define if you have the ANSI C header files. */
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
83 +#define STDC_HEADERS 1
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
84 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
85 #include <stdio.h>
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
86 #if HAVE_SYS_TYPES_H
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
87 # include <sys/types.h>
16249
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
88 @@ -329,7 +329,7 @@
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
89 }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
90
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
91
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
92 - #if defined(_WIN32) && !defined(__MINGW32__)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
93 + #if defined(_WIN32) && !defined(__MINGW32__) && !defined(HAVE_LRINTF)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
94 #define HAS_LRINTF
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
95 static INLINE int lrintf(float f)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
96 {
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
97 @@ -341,7 +341,7 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
98 }
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
99 return i;
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
100 }
16249
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
101 - #elif (defined(__i386__) && defined(__GNUC__)) && !defined(__MINGW32__)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
102 + #elif (defined(__i386__) && defined(__GNUC__)) && !defined(__MINGW32__) && !defined(HAVE_LRINTF)
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
103 #define HAS_LRINTF
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
104 // from http://www.stereopsis.com/FPU.html
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
105 static INLINE int lrintf(float f)
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
106 @@ -340,6 +370,8 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
107
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
108 #else
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
109
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
110 +#include <math.h>
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
111 +
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
112 #ifdef HAVE_LRINTF
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
113 # define HAS_LRINTF
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
114 # define _ISOC9X_SOURCE 1
14858
cc0c5443548d cosmetics: Make diff -R apply without offsets.
diego
parents: 14712
diff changeset
115 @@ -348,8 +380,6 @@
14712
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
116 # define __USE_ISOC99 1
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
117 #endif
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
118
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
119 - #include <math.h>
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
120 -
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
121 #ifdef HAVE_SINF
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
122 # define sin sinf
ca694d6b5375 MPlayer-specific changes to libfaad
diego
parents:
diff changeset
123 #error
16249
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
124 --- main/libfaad2/output.c 2005/02/19 01:21:19 1.7
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
125 +++ main/libfaad2/output.c 2005/03/29 18:14:24 1.8
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
126 @@ -19,10 +19,9 @@
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
127 ** Any non-GPL usage of this software or parts of this software is strictly
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
128 ** forbidden.
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
129 **
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
130 -** Commercial non-GPL licensing of this software is possible.
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
131 -** For more info contact Ahead Software through Mpeg4AAClicense@nero.com.
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
132 -**
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
133 -** $Id: output.c,v 1.8 2005/03/29 18:14:24 rfelker Exp $
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
134 +** Initially modified for use with MPlayer by Rich Felker on 2005/03/29
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
135 +** $Id: output.c,v 1.11 2005/04/05 05:43:41 rfelker Exp $
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
136 +** detailed CVS changelog at http://www.mplayerhq.hu/cgi-bin/cvsweb.cgi/main/
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
137 **/
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
138
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
139 #include "common.h"
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
140 @@ -462,7 +462,7 @@
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
141 }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
142 }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
143
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
144 -void* output_to_PCM(NeAACDecHandle hDecoder,
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
145 +void* output_to_PCM_sux(NeAACDecHandle hDecoder,
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
146 real_t **input, void *sample_buffer, uint8_t channels,
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
147 uint16_t frame_len, uint8_t format)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
148 {
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
149 @@ -553,4 +553,51 @@
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
150 return sample_buffer;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
151 }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
152
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
153 +void* output_to_PCM(NeAACDecHandle hDecoder,
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
154 + real_t **input, void *sample_buffer, uint8_t channels,
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
155 + uint16_t frame_len, uint8_t format)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
156 +{
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
157 + int ch;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
158 + int i;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
159 + int16_t *short_sample_buffer = (int16_t*)sample_buffer;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
160 + real_t *ch0 = input[hDecoder->internal_channel[0]];
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
161 + real_t *ch1 = input[hDecoder->internal_channel[1]];
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
162 + real_t *ch2 = input[hDecoder->internal_channel[2]];
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
163 + real_t *ch3 = input[hDecoder->internal_channel[3]];
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
164 + real_t *ch4 = input[hDecoder->internal_channel[4]];
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
165 +
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
166 + if (format != FAAD_FMT_16BIT)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
167 + return output_to_PCM_sux(hDecoder, input, sample_buffer, channels, frame_len, format);
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
168 +
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
169 + if (hDecoder->downMatrix) {
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
170 + for(i = 0; i < frame_len; i++)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
171 + {
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
172 + int32_t tmp;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
173 + tmp = (ch1[i] + ((ch0[i]+ch3[i])>>1) + ((ch0[i]+ch3[i])>>2) + (1<<(REAL_BITS))) >> (REAL_BITS+1);
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
174 + if ((tmp+0x8000) & ~0xffff) tmp = ~(tmp>>31)-0x8000;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
175 + short_sample_buffer[0] = tmp;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
176 + tmp = (ch2[i] + ((ch0[i]+ch4[i])>>1) + ((ch0[i]+ch4[i])>>2) + (1<<(REAL_BITS))) >> (REAL_BITS+1);
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
177 + if ((tmp+0x8000) & ~0xffff) tmp = ~(tmp>>31)-0x8000;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
178 + short_sample_buffer[1] = tmp;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
179 + short_sample_buffer += channels;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
180 + }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
181 + return sample_buffer;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
182 + }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
183 +
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
184 + /* Copy output to a standard PCM buffer */
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
185 + for(i = 0; i < frame_len; i++)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
186 + {
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
187 + for (ch = 0; ch < channels; ch++)
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
188 + {
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
189 + int32_t tmp = input[ch][i];
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
190 + tmp += (1 << (REAL_BITS-1));
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
191 + tmp >>= REAL_BITS;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
192 + if ((tmp+0x8000) & ~0xffff) tmp = ~(tmp>>31)-0x8000;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
193 + *(short_sample_buffer++) = tmp;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
194 + }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
195 + }
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
196 +
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
197 + return sample_buffer;
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
198 +}
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
199 +
d47cd711f617 Update for latest changes.
diego
parents: 14858
diff changeset
200 #endif