Mercurial > almixer_isolated
annotate Isolated/SoundDecoder.h @ 79:358b0bd5df43 tip
Added support for Apportable's alcSuspend()/alcResume() in BeginInterruption()/EndInterruption. You must define ALMIXER_USE_APPORTABLE_OPENAL_EXTENSIONS to compile in this support.
author | Eric Wing <ewing@coronalabs.com> |
---|---|
date | Tue, 30 Oct 2012 16:01:30 -0700 |
parents | 398d1cb12448 |
children |
rev | line source |
---|---|
38 | 1 |
2 /* | |
3 * This is a wrapper interface that tries to provide a similar | |
4 * front-end interface to SDL_sound. | |
5 */ | |
6 | |
7 #ifndef SOUNDDECODER_H | |
8 #define SOUNDDECODER_H | |
9 | |
10 #ifdef __cplusplus | |
11 extern "C" { | |
12 #endif | |
13 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
14 #if defined(_WIN32) |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
15 #if defined(SOUND_DECODER_BUILD_LIBRARY) |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
16 #define SOUND_DECODER_DECLSPEC __declspec(dllexport) |
72
398d1cb12448
Bug fix for unbalanced #if/#endif blocks. I think I broke it when removing the dllimport for Windows.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
71
diff
changeset
|
17 #else |
398d1cb12448
Bug fix for unbalanced #if/#endif blocks. I think I broke it when removing the dllimport for Windows.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
71
diff
changeset
|
18 #define SOUND_DECODER_DECLSPEC |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
19 #endif |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
20 #else |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
21 #if defined(SOUND_DECODER_BUILD_LIBRARY) |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
22 #if defined (__GNUC__) && __GNUC__ >= 4 |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
23 #define SOUND_DECODER_DECLSPEC __attribute__((visibility("default"))) |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
24 #else |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
25 #define SOUND_DECODER_DECLSPEC |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
26 #endif |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
27 #else |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
28 #define SOUND_DECODER_DECLSPEC |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
29 #endif |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
30 #endif |
38 | 31 |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
32 #if defined(_WIN32) |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
33 #define SOUND_DECODER_CALL __cdecl |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
34 #else |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
35 #define SOUND_DECODER_CALL |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
36 #endif |
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
37 |
38 | 38 #include <stdint.h> |
39 #include <stddef.h> | |
40 | |
41 #include "al.h" /* OpenAL */ | |
42 | |
43 /* Compatibility defines for SDL */ | |
44 #define AUDIO_U8 0x0008 | |
45 #define AUDIO_S8 0x8008 | |
46 #define AUDIO_U16LSB 0x0010 | |
47 #define AUDIO_S16LSB 0x8010 | |
48 #define AUDIO_U16MSB 0x1010 | |
49 #define AUDIO_S16MSB 0x9010 | |
50 #define AUDIO_U16 AUDIO_U16LSB | |
51 #define AUDIO_S16 AUDIO_S16LSB | |
52 | |
70
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
53 /* Apple defines __BIG_ENDIAN__ and __LITTLE_ENDIAN__ appropriately. |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
54 * Linux provides <endian.h> |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
55 */ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
56 #if !defined(__BIG_ENDIAN__) && !defined(__LITTLE_ENDIAN__) |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
57 #ifdef __linux__ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
58 #include <endian.h> |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
59 #if _BYTE_ORDER == _BIG_ENDIAN |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
60 #define __BIG_ENDIAN__ 1 |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
61 #else |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
62 #define __LITTLE_ENDIAN__ 1 |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
63 #endif |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
64 #else /* __linux __ */ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
65 #if defined(__hppa__) || \ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
66 defined(__m68k__) || defined(mc68000) || defined(_M_M68K) || \ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
67 (defined(__MIPS__) && defined(__MISPEB__)) || \ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
68 defined(__ppc__) || defined(__POWERPC__) || defined(_M_PPC) || \ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
69 defined(__sparc__) |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
70 |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
71 #define __BIG_ENDIAN__ 1 |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
72 #else |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
73 #define __LITTLE_ENDIAN__ 1 |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
74 #endif |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
75 #endif /* __linux __ */ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
76 #endif /* */ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
77 |
38 | 78 |
79 #if __BIG_ENDIAN__ | |
70
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
80 /* #warning "Using __BIG_ENDIAN__" */ |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
81 #define AUDIO_U16SYS AUDIO_U16MSB |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
82 #define AUDIO_S16SYS AUDIO_S16MSB |
38 | 83 #elif __LITTLE_ENDIAN__ |
70
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
84 #define AUDIO_U16SYS AUDIO_U16LSB |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
85 #define AUDIO_S16SYS AUDIO_S16LSB |
38 | 86 #else |
70
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
87 #warning "Using __LITTLE_ENDIAN__ as fallback" |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
88 #define AUDIO_U16SYS AUDIO_U16LSB |
7d63f5149d40
Enhanced endian detection code in SoundDecoder.h after reviewing ANDROID_NDK changes.
Eric Wing <ewing . public |-at-| gmail . com>
parents:
69
diff
changeset
|
89 #define AUDIO_S16SYS AUDIO_S16LSB |
38 | 90 #endif |
91 | |
92 struct ALmixer_RWops; | |
93 | |
94 typedef enum | |
95 { | |
96 SOUND_SAMPLEFLAG_NONE = 0, | |
97 SOUND_SAMPLEFLAG_CANSEEK = 1, | |
98 SOUND_SAMPLEFLAG_EOF = 1 << 29, | |
99 SOUND_SAMPLEFLAG_ERROR = 1 << 30, | |
100 SOUND_SAMPLEFLAG_EAGAIN = 1 << 31 | |
101 } SoundDecoder_SampleFlags; | |
102 | |
103 #define Sound_SampleFlags SoundDecoder_SampleFlags; | |
104 | |
105 typedef struct SoundDecoder_AudioInfo | |
106 { | |
107 //uint16_t format; /**< Equivalent of SDL_AudioSpec.format. */ | |
108 ALushort format; /**< Equivalent of SDL_AudioSpec.format. */ | |
109 ALubyte channels; | |
110 // uint8_t channels; | |
111 //uint32_t rate; | |
112 ALuint rate; | |
113 } SoundDecoder_AudioInfo; | |
114 | |
115 //#define Sound_AudioInfo SoundDecoder_AudioInfo; | |
116 typedef struct SoundDecoder_AudioInfo Sound_AudioInfo; | |
117 | |
118 | |
119 | |
120 typedef struct SoundDecoder_DecoderInfo | |
121 { | |
122 const char** extensions; | |
123 const char* description; | |
124 const char* author; | |
125 const char* url; | |
126 } SoundDecoder_DecoderInfo; | |
127 | |
128 //#define Sound_DecoderInfo SoundDecoder_DecoderInfo; | |
129 typedef struct SoundDecoder_DecoderInfo Sound_DecoderInfo; | |
130 | |
131 | |
132 | |
133 typedef struct SoundDecoder_Sample | |
134 { | |
135 void* opaque; | |
136 const SoundDecoder_DecoderInfo* decoder; | |
137 SoundDecoder_AudioInfo desired; | |
138 SoundDecoder_AudioInfo actual; | |
139 void *buffer; | |
140 size_t buffer_size; | |
141 SoundDecoder_SampleFlags flags; | |
142 } SoundDecoder_Sample; | |
143 | |
144 //#define Sound_Sample SoundDecoder_Sample; | |
145 typedef struct SoundDecoder_Sample Sound_Sample; | |
146 | |
147 | |
148 typedef struct SoundDecoder_Version | |
149 { | |
150 int major; | |
151 int minor; | |
152 int patch; | |
153 } SoundDecoder_Version; | |
154 | |
155 //#define Sound_Version SoundDecoder_Version; | |
156 typedef struct SoundDecoder_Version Sound_Version; | |
157 | |
158 | |
159 #define SOUNDDECODER_VER_MAJOR 0 | |
160 #define SOUNDDECODER_VER_MINOR 0 | |
161 #define SOUNDDECODER_VER_PATCH 1 | |
162 | |
163 #define SOUNDDECODER_VERSION(x) \ | |
164 { \ | |
165 (x)->major = SOUNDDECODER_VER_MAJOR; \ | |
166 (x)->minor = SOUNDDECODER_VER_MINOR; \ | |
167 (x)->patch = SOUNDDECODER_VER_PATCH; \ | |
168 } | |
169 | |
170 #define SOUND_VERSION SOUNDDECODER_VERSION | |
171 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
172 extern SOUND_DECODER_DECLSPEC void SOUND_DECODER_CALL SoundDecoder_GetLinkedVersion(SoundDecoder_Version *ver); |
38 | 173 #define Sound_GetLinkedVersion SoundDecoder_GetLinkedVersion |
174 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
175 extern SOUND_DECODER_DECLSPEC int SOUND_DECODER_CALL SoundDecoder_Init(void); |
38 | 176 #define Sound_Init SoundDecoder_Init |
177 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
178 extern SOUND_DECODER_DECLSPEC void SOUND_DECODER_CALL SoundDecoder_Quit(void); |
38 | 179 #define Sound_Quit SoundDecoder_Quit |
180 | |
181 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
182 extern SOUND_DECODER_DECLSPEC const SOUND_DECODER_CALL SoundDecoder_DecoderInfo** SoundDecoder_AvailableDecoders(void); |
38 | 183 #define Sound_AvailableDecoders SoundDecoder_AvailableDecoders |
184 | |
185 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
186 extern SOUND_DECODER_DECLSPEC const char* SOUND_DECODER_CALL SoundDecoder_GetError(void); |
38 | 187 #define Sound_GetError SoundDecoder_GetError |
188 | |
189 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
190 extern SOUND_DECODER_DECLSPEC void SOUND_DECODER_CALL SoundDecoder_ClearError(void); |
38 | 191 #define Sound_ClearError SoundDecoder_ClearError |
192 | |
193 | |
194 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
195 extern SOUND_DECODER_DECLSPEC SoundDecoder_Sample* SOUND_DECODER_CALL SoundDecoder_NewSample( |
38 | 196 struct ALmixer_RWops* rw_ops, |
197 const char* ext, | |
198 SoundDecoder_AudioInfo* desired, | |
199 size_t buffer_size); | |
200 #define Sound_NewSample SoundDecoder_NewSample | |
201 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
202 extern SOUND_DECODER_DECLSPEC SoundDecoder_Sample* SOUND_DECODER_CALL SoundDecoder_NewSampleFromFile(const char* file_name, |
38 | 203 SoundDecoder_AudioInfo* desired, |
204 size_t bufferSize); | |
205 #define Sound_NewSampleFromFile SoundDecoder_NewSampleFromFile | |
206 | |
207 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
208 extern SOUND_DECODER_DECLSPEC void SOUND_DECODER_CALL SoundDecoder_FreeSample(SoundDecoder_Sample* sound_sample); |
38 | 209 #define Sound_FreeSample SoundDecoder_FreeSample |
210 | |
211 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
212 extern SOUND_DECODER_DECLSPEC ptrdiff_t SOUND_DECODER_CALL SoundDecoder_GetDuration(SoundDecoder_Sample* sound_sample); |
38 | 213 #define Sound_GetDuration SoundDecoder_GetDuration |
214 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
215 extern SOUND_DECODER_DECLSPEC int SOUND_DECODER_CALL SoundDecoder_SetBufferSize(SoundDecoder_Sample* sound_sample, size_t new_buffer_size); |
38 | 216 #define Sound_SetBufferSize SoundDecoder_SetBufferSize |
217 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
218 extern SOUND_DECODER_DECLSPEC size_t SOUND_DECODER_CALL SoundDecoder_Decode(SoundDecoder_Sample* sound_sample); |
38 | 219 #define Sound_Decode SoundDecoder_Decode |
220 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
221 extern SOUND_DECODER_DECLSPEC size_t SOUND_DECODER_CALL SoundDecoder_DecodeAll(SoundDecoder_Sample* sound_sample); |
38 | 222 #define Sound_DecodeAll SoundDecoder_DecodeAll |
223 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
224 extern SOUND_DECODER_DECLSPEC int SOUND_DECODER_CALL SoundDecoder_Rewind(SoundDecoder_Sample* sound_sample); |
38 | 225 #define Sound_Rewind SoundDecoder_Rewind |
226 | |
56
208a9ed20087
Added explicit symbol visibility markers to audio support files in ALmixer for public headers so they can be built as a dynamic library if needed.
Eric Wing <ewing@anscamobile.com>
parents:
38
diff
changeset
|
227 extern SOUND_DECODER_DECLSPEC int SOUND_DECODER_CALL SoundDecoder_Seek(SoundDecoder_Sample* sound_sample, size_t ms); |
38 | 228 #define Sound_Seek SoundDecoder_Seek |
229 | |
230 | |
231 /* Ends C function definitions when using C++ */ | |
232 #ifdef __cplusplus | |
233 } | |
234 #endif | |
235 | |
236 #endif | |
237 |