rlm@0
|
1 #ifndef AL_AL_H
|
rlm@0
|
2 #define AL_AL_H
|
rlm@0
|
3
|
rlm@0
|
4 #if defined(__cplusplus)
|
rlm@0
|
5 extern "C" {
|
rlm@0
|
6 #endif
|
rlm@0
|
7
|
rlm@0
|
8 #ifndef AL_API
|
rlm@0
|
9 #if defined(AL_LIBTYPE_STATIC)
|
rlm@0
|
10 #define AL_API
|
rlm@0
|
11 #elif defined(_WIN32)
|
rlm@0
|
12 #define AL_API __declspec(dllimport)
|
rlm@0
|
13 #else
|
rlm@0
|
14 #define AL_API extern
|
rlm@0
|
15 #endif
|
rlm@0
|
16 #endif
|
rlm@0
|
17
|
rlm@0
|
18 #if defined(_WIN32)
|
rlm@0
|
19 #define AL_APIENTRY __cdecl
|
rlm@0
|
20 #else
|
rlm@0
|
21 #define AL_APIENTRY
|
rlm@0
|
22 #endif
|
rlm@0
|
23
|
rlm@0
|
24 #if defined(TARGET_OS_MAC) && TARGET_OS_MAC
|
rlm@0
|
25 #pragma export on
|
rlm@0
|
26 #endif
|
rlm@0
|
27
|
rlm@0
|
28 /*
|
rlm@0
|
29 * The OPENAL, ALAPI, ALAPIENTRY, AL_INVALID, AL_ILLEGAL_ENUM, and
|
rlm@0
|
30 * AL_ILLEGAL_COMMAND macros are deprecated, but are included for
|
rlm@0
|
31 * applications porting code from AL 1.0
|
rlm@0
|
32 */
|
rlm@0
|
33 #define OPENAL
|
rlm@0
|
34 #define ALAPI AL_API
|
rlm@0
|
35 #define ALAPIENTRY AL_APIENTRY
|
rlm@0
|
36 #define AL_INVALID (-1)
|
rlm@0
|
37 #define AL_ILLEGAL_ENUM AL_INVALID_ENUM
|
rlm@0
|
38 #define AL_ILLEGAL_COMMAND AL_INVALID_OPERATION
|
rlm@0
|
39
|
rlm@0
|
40 #define AL_VERSION_1_0
|
rlm@0
|
41 #define AL_VERSION_1_1
|
rlm@0
|
42
|
rlm@0
|
43
|
rlm@0
|
44 /** 8-bit boolean */
|
rlm@0
|
45 typedef char ALboolean;
|
rlm@0
|
46
|
rlm@0
|
47 /** character */
|
rlm@0
|
48 typedef char ALchar;
|
rlm@0
|
49
|
rlm@0
|
50 /** signed 8-bit 2's complement integer */
|
rlm@0
|
51 typedef signed char ALbyte;
|
rlm@0
|
52
|
rlm@0
|
53 /** unsigned 8-bit integer */
|
rlm@0
|
54 typedef unsigned char ALubyte;
|
rlm@0
|
55
|
rlm@0
|
56 /** signed 16-bit 2's complement integer */
|
rlm@0
|
57 typedef short ALshort;
|
rlm@0
|
58
|
rlm@0
|
59 /** unsigned 16-bit integer */
|
rlm@0
|
60 typedef unsigned short ALushort;
|
rlm@0
|
61
|
rlm@0
|
62 /** signed 32-bit 2's complement integer */
|
rlm@0
|
63 typedef int ALint;
|
rlm@0
|
64
|
rlm@0
|
65 /** unsigned 32-bit integer */
|
rlm@0
|
66 typedef unsigned int ALuint;
|
rlm@0
|
67
|
rlm@0
|
68 /** non-negative 32-bit binary integer size */
|
rlm@0
|
69 typedef int ALsizei;
|
rlm@0
|
70
|
rlm@0
|
71 /** enumerated 32-bit value */
|
rlm@0
|
72 typedef int ALenum;
|
rlm@0
|
73
|
rlm@0
|
74 /** 32-bit IEEE754 floating-point */
|
rlm@0
|
75 typedef float ALfloat;
|
rlm@0
|
76
|
rlm@0
|
77 /** 64-bit IEEE754 floating-point */
|
rlm@0
|
78 typedef double ALdouble;
|
rlm@0
|
79
|
rlm@0
|
80 /** void type (for opaque pointers only) */
|
rlm@0
|
81 typedef void ALvoid;
|
rlm@0
|
82
|
rlm@0
|
83
|
rlm@0
|
84 /* Enumerant values begin at column 50. No tabs. */
|
rlm@0
|
85
|
rlm@0
|
86 /* "no distance model" or "no buffer" */
|
rlm@0
|
87 #define AL_NONE 0
|
rlm@0
|
88
|
rlm@0
|
89 /* Boolean False. */
|
rlm@0
|
90 #define AL_FALSE 0
|
rlm@0
|
91
|
rlm@0
|
92 /** Boolean True. */
|
rlm@0
|
93 #define AL_TRUE 1
|
rlm@0
|
94
|
rlm@0
|
95 /** Indicate Source has relative coordinates. */
|
rlm@0
|
96 #define AL_SOURCE_RELATIVE 0x202
|
rlm@0
|
97
|
rlm@0
|
98
|
rlm@0
|
99
|
rlm@0
|
100 /**
|
rlm@0
|
101 * Directional source, inner cone angle, in degrees.
|
rlm@0
|
102 * Range: [0-360]
|
rlm@0
|
103 * Default: 360
|
rlm@0
|
104 */
|
rlm@0
|
105 #define AL_CONE_INNER_ANGLE 0x1001
|
rlm@0
|
106
|
rlm@0
|
107 /**
|
rlm@0
|
108 * Directional source, outer cone angle, in degrees.
|
rlm@0
|
109 * Range: [0-360]
|
rlm@0
|
110 * Default: 360
|
rlm@0
|
111 */
|
rlm@0
|
112 #define AL_CONE_OUTER_ANGLE 0x1002
|
rlm@0
|
113
|
rlm@0
|
114 /**
|
rlm@0
|
115 * Specify the pitch to be applied at source.
|
rlm@0
|
116 * Range: [0.5-2.0]
|
rlm@0
|
117 * Default: 1.0
|
rlm@0
|
118 */
|
rlm@0
|
119 #define AL_PITCH 0x1003
|
rlm@0
|
120
|
rlm@0
|
121 /**
|
rlm@0
|
122 * Specify the current location in three dimensional space.
|
rlm@0
|
123 * OpenAL, like OpenGL, uses a right handed coordinate system,
|
rlm@0
|
124 * where in a frontal default view X (thumb) points right,
|
rlm@0
|
125 * Y points up (index finger), and Z points towards the
|
rlm@0
|
126 * viewer/camera (middle finger).
|
rlm@0
|
127 * To switch from a left handed coordinate system, flip the
|
rlm@0
|
128 * sign on the Z coordinate.
|
rlm@0
|
129 * Listener position is always in the world coordinate system.
|
rlm@0
|
130 */
|
rlm@0
|
131 #define AL_POSITION 0x1004
|
rlm@0
|
132
|
rlm@0
|
133 /** Specify the current direction. */
|
rlm@0
|
134 #define AL_DIRECTION 0x1005
|
rlm@0
|
135
|
rlm@0
|
136 /** Specify the current velocity in three dimensional space. */
|
rlm@0
|
137 #define AL_VELOCITY 0x1006
|
rlm@0
|
138
|
rlm@0
|
139 /**
|
rlm@0
|
140 * Indicate whether source is looping.
|
rlm@0
|
141 * Type: ALboolean?
|
rlm@0
|
142 * Range: [AL_TRUE, AL_FALSE]
|
rlm@0
|
143 * Default: FALSE.
|
rlm@0
|
144 */
|
rlm@0
|
145 #define AL_LOOPING 0x1007
|
rlm@0
|
146
|
rlm@0
|
147 /**
|
rlm@0
|
148 * Indicate the buffer to provide sound samples.
|
rlm@0
|
149 * Type: ALuint.
|
rlm@0
|
150 * Range: any valid Buffer id.
|
rlm@0
|
151 */
|
rlm@0
|
152 #define AL_BUFFER 0x1009
|
rlm@0
|
153
|
rlm@0
|
154 /**
|
rlm@0
|
155 * Indicate the gain (volume amplification) applied.
|
rlm@0
|
156 * Type: ALfloat.
|
rlm@0
|
157 * Range: ]0.0- ]
|
rlm@0
|
158 * A value of 1.0 means un-attenuated/unchanged.
|
rlm@0
|
159 * Each division by 2 equals an attenuation of -6dB.
|
rlm@0
|
160 * Each multiplicaton with 2 equals an amplification of +6dB.
|
rlm@0
|
161 * A value of 0.0 is meaningless with respect to a logarithmic
|
rlm@0
|
162 * scale; it is interpreted as zero volume - the channel
|
rlm@0
|
163 * is effectively disabled.
|
rlm@0
|
164 */
|
rlm@0
|
165 #define AL_GAIN 0x100A
|
rlm@0
|
166
|
rlm@0
|
167 /*
|
rlm@0
|
168 * Indicate minimum source attenuation
|
rlm@0
|
169 * Type: ALfloat
|
rlm@0
|
170 * Range: [0.0 - 1.0]
|
rlm@0
|
171 *
|
rlm@0
|
172 * Logarthmic
|
rlm@0
|
173 */
|
rlm@0
|
174 #define AL_MIN_GAIN 0x100D
|
rlm@0
|
175
|
rlm@0
|
176 /**
|
rlm@0
|
177 * Indicate maximum source attenuation
|
rlm@0
|
178 * Type: ALfloat
|
rlm@0
|
179 * Range: [0.0 - 1.0]
|
rlm@0
|
180 *
|
rlm@0
|
181 * Logarthmic
|
rlm@0
|
182 */
|
rlm@0
|
183 #define AL_MAX_GAIN 0x100E
|
rlm@0
|
184
|
rlm@0
|
185 /**
|
rlm@0
|
186 * Indicate listener orientation.
|
rlm@0
|
187 *
|
rlm@0
|
188 * at/up
|
rlm@0
|
189 */
|
rlm@0
|
190 #define AL_ORIENTATION 0x100F
|
rlm@0
|
191
|
rlm@0
|
192 /**
|
rlm@0
|
193 * Source state information.
|
rlm@0
|
194 */
|
rlm@0
|
195 #define AL_SOURCE_STATE 0x1010
|
rlm@0
|
196 #define AL_INITIAL 0x1011
|
rlm@0
|
197 #define AL_PLAYING 0x1012
|
rlm@0
|
198 #define AL_PAUSED 0x1013
|
rlm@0
|
199 #define AL_STOPPED 0x1014
|
rlm@0
|
200
|
rlm@0
|
201 /**
|
rlm@0
|
202 * Buffer Queue params
|
rlm@0
|
203 */
|
rlm@0
|
204 #define AL_BUFFERS_QUEUED 0x1015
|
rlm@0
|
205 #define AL_BUFFERS_PROCESSED 0x1016
|
rlm@0
|
206
|
rlm@0
|
207 /**
|
rlm@0
|
208 * Source buffer position information
|
rlm@0
|
209 */
|
rlm@0
|
210 #define AL_SEC_OFFSET 0x1024
|
rlm@0
|
211 #define AL_SAMPLE_OFFSET 0x1025
|
rlm@0
|
212 #define AL_BYTE_OFFSET 0x1026
|
rlm@0
|
213
|
rlm@0
|
214 /*
|
rlm@0
|
215 * Source type (Static, Streaming or undetermined)
|
rlm@0
|
216 * Source is Static if a Buffer has been attached using AL_BUFFER
|
rlm@0
|
217 * Source is Streaming if one or more Buffers have been attached using alSourceQueueBuffers
|
rlm@0
|
218 * Source is undetermined when it has the NULL buffer attached
|
rlm@0
|
219 */
|
rlm@0
|
220 #define AL_SOURCE_TYPE 0x1027
|
rlm@0
|
221 #define AL_STATIC 0x1028
|
rlm@0
|
222 #define AL_STREAMING 0x1029
|
rlm@0
|
223 #define AL_UNDETERMINED 0x1030
|
rlm@0
|
224
|
rlm@0
|
225 /** Sound samples: format specifier. */
|
rlm@0
|
226 #define AL_FORMAT_MONO8 0x1100
|
rlm@0
|
227 #define AL_FORMAT_MONO16 0x1101
|
rlm@0
|
228 #define AL_FORMAT_STEREO8 0x1102
|
rlm@0
|
229 #define AL_FORMAT_STEREO16 0x1103
|
rlm@0
|
230
|
rlm@0
|
231 /**
|
rlm@0
|
232 * source specific reference distance
|
rlm@0
|
233 * Type: ALfloat
|
rlm@0
|
234 * Range: 0.0 - +inf
|
rlm@0
|
235 *
|
rlm@0
|
236 * At 0.0, no distance attenuation occurs. Default is
|
rlm@0
|
237 * 1.0.
|
rlm@0
|
238 */
|
rlm@0
|
239 #define AL_REFERENCE_DISTANCE 0x1020
|
rlm@0
|
240
|
rlm@0
|
241 /**
|
rlm@0
|
242 * source specific rolloff factor
|
rlm@0
|
243 * Type: ALfloat
|
rlm@0
|
244 * Range: 0.0 - +inf
|
rlm@0
|
245 *
|
rlm@0
|
246 */
|
rlm@0
|
247 #define AL_ROLLOFF_FACTOR 0x1021
|
rlm@0
|
248
|
rlm@0
|
249 /**
|
rlm@0
|
250 * Directional source, outer cone gain.
|
rlm@0
|
251 *
|
rlm@0
|
252 * Default: 0.0
|
rlm@0
|
253 * Range: [0.0 - 1.0]
|
rlm@0
|
254 * Logarithmic
|
rlm@0
|
255 */
|
rlm@0
|
256 #define AL_CONE_OUTER_GAIN 0x1022
|
rlm@0
|
257
|
rlm@0
|
258 /**
|
rlm@0
|
259 * Indicate distance above which sources are not
|
rlm@0
|
260 * attenuated using the inverse clamped distance model.
|
rlm@0
|
261 *
|
rlm@0
|
262 * Default: +inf
|
rlm@0
|
263 * Type: ALfloat
|
rlm@0
|
264 * Range: 0.0 - +inf
|
rlm@0
|
265 */
|
rlm@0
|
266 #define AL_MAX_DISTANCE 0x1023
|
rlm@0
|
267
|
rlm@0
|
268 /**
|
rlm@0
|
269 * Sound samples: frequency, in units of Hertz [Hz].
|
rlm@0
|
270 * This is the number of samples per second. Half of the
|
rlm@0
|
271 * sample frequency marks the maximum significant
|
rlm@0
|
272 * frequency component.
|
rlm@0
|
273 */
|
rlm@0
|
274 #define AL_FREQUENCY 0x2001
|
rlm@0
|
275 #define AL_BITS 0x2002
|
rlm@0
|
276 #define AL_CHANNELS 0x2003
|
rlm@0
|
277 #define AL_SIZE 0x2004
|
rlm@0
|
278
|
rlm@0
|
279 /**
|
rlm@0
|
280 * Buffer state.
|
rlm@0
|
281 *
|
rlm@0
|
282 * Not supported for public use (yet).
|
rlm@0
|
283 */
|
rlm@0
|
284 #define AL_UNUSED 0x2010
|
rlm@0
|
285 #define AL_PENDING 0x2011
|
rlm@0
|
286 #define AL_PROCESSED 0x2012
|
rlm@0
|
287
|
rlm@0
|
288
|
rlm@0
|
289 /** Errors: No Error. */
|
rlm@0
|
290 #define AL_NO_ERROR AL_FALSE
|
rlm@0
|
291
|
rlm@0
|
292 /**
|
rlm@0
|
293 * Invalid Name paramater passed to AL call.
|
rlm@0
|
294 */
|
rlm@0
|
295 #define AL_INVALID_NAME 0xA001
|
rlm@0
|
296
|
rlm@0
|
297 /**
|
rlm@0
|
298 * Invalid parameter passed to AL call.
|
rlm@0
|
299 */
|
rlm@0
|
300 #define AL_INVALID_ENUM 0xA002
|
rlm@0
|
301
|
rlm@0
|
302 /**
|
rlm@0
|
303 * Invalid enum parameter value.
|
rlm@0
|
304 */
|
rlm@0
|
305 #define AL_INVALID_VALUE 0xA003
|
rlm@0
|
306
|
rlm@0
|
307 /**
|
rlm@0
|
308 * Illegal call.
|
rlm@0
|
309 */
|
rlm@0
|
310 #define AL_INVALID_OPERATION 0xA004
|
rlm@0
|
311
|
rlm@0
|
312
|
rlm@0
|
313 /**
|
rlm@0
|
314 * No mojo.
|
rlm@0
|
315 */
|
rlm@0
|
316 #define AL_OUT_OF_MEMORY 0xA005
|
rlm@0
|
317
|
rlm@0
|
318
|
rlm@0
|
319 /** Context strings: Vendor Name. */
|
rlm@0
|
320 #define AL_VENDOR 0xB001
|
rlm@0
|
321 #define AL_VERSION 0xB002
|
rlm@0
|
322 #define AL_RENDERER 0xB003
|
rlm@0
|
323 #define AL_EXTENSIONS 0xB004
|
rlm@0
|
324
|
rlm@0
|
325 /** Global tweakage. */
|
rlm@0
|
326
|
rlm@0
|
327 /**
|
rlm@0
|
328 * Doppler scale. Default 1.0
|
rlm@0
|
329 */
|
rlm@0
|
330 #define AL_DOPPLER_FACTOR 0xC000
|
rlm@0
|
331
|
rlm@0
|
332 /**
|
rlm@0
|
333 * Tweaks speed of propagation.
|
rlm@0
|
334 */
|
rlm@0
|
335 #define AL_DOPPLER_VELOCITY 0xC001
|
rlm@0
|
336
|
rlm@0
|
337 /**
|
rlm@0
|
338 * Speed of Sound in units per second
|
rlm@0
|
339 */
|
rlm@0
|
340 #define AL_SPEED_OF_SOUND 0xC003
|
rlm@0
|
341
|
rlm@0
|
342 /**
|
rlm@0
|
343 * Distance models
|
rlm@0
|
344 *
|
rlm@0
|
345 * used in conjunction with DistanceModel
|
rlm@0
|
346 *
|
rlm@0
|
347 * implicit: NONE, which disances distance attenuation.
|
rlm@0
|
348 */
|
rlm@0
|
349 #define AL_DISTANCE_MODEL 0xD000
|
rlm@0
|
350 #define AL_INVERSE_DISTANCE 0xD001
|
rlm@0
|
351 #define AL_INVERSE_DISTANCE_CLAMPED 0xD002
|
rlm@0
|
352 #define AL_LINEAR_DISTANCE 0xD003
|
rlm@0
|
353 #define AL_LINEAR_DISTANCE_CLAMPED 0xD004
|
rlm@0
|
354 #define AL_EXPONENT_DISTANCE 0xD005
|
rlm@0
|
355 #define AL_EXPONENT_DISTANCE_CLAMPED 0xD006
|
rlm@0
|
356
|
rlm@0
|
357 /*
|
rlm@0
|
358 * Renderer State management
|
rlm@0
|
359 */
|
rlm@0
|
360 AL_API void AL_APIENTRY alEnable( ALenum capability );
|
rlm@0
|
361
|
rlm@0
|
362 AL_API void AL_APIENTRY alDisable( ALenum capability );
|
rlm@0
|
363
|
rlm@0
|
364 AL_API ALboolean AL_APIENTRY alIsEnabled( ALenum capability );
|
rlm@0
|
365
|
rlm@0
|
366
|
rlm@0
|
367 /*
|
rlm@0
|
368 * State retrieval
|
rlm@0
|
369 */
|
rlm@0
|
370 AL_API const ALchar* AL_APIENTRY alGetString( ALenum param );
|
rlm@0
|
371
|
rlm@0
|
372 AL_API void AL_APIENTRY alGetBooleanv( ALenum param, ALboolean* data );
|
rlm@0
|
373
|
rlm@0
|
374 AL_API void AL_APIENTRY alGetIntegerv( ALenum param, ALint* data );
|
rlm@0
|
375
|
rlm@0
|
376 AL_API void AL_APIENTRY alGetFloatv( ALenum param, ALfloat* data );
|
rlm@0
|
377
|
rlm@0
|
378 AL_API void AL_APIENTRY alGetDoublev( ALenum param, ALdouble* data );
|
rlm@0
|
379
|
rlm@0
|
380 AL_API ALboolean AL_APIENTRY alGetBoolean( ALenum param );
|
rlm@0
|
381
|
rlm@0
|
382 AL_API ALint AL_APIENTRY alGetInteger( ALenum param );
|
rlm@0
|
383
|
rlm@0
|
384 AL_API ALfloat AL_APIENTRY alGetFloat( ALenum param );
|
rlm@0
|
385
|
rlm@0
|
386 AL_API ALdouble AL_APIENTRY alGetDouble( ALenum param );
|
rlm@0
|
387
|
rlm@0
|
388
|
rlm@0
|
389 /*
|
rlm@0
|
390 * Error support.
|
rlm@0
|
391 * Obtain the most recent error generated in the AL state machine.
|
rlm@0
|
392 */
|
rlm@0
|
393 AL_API ALenum AL_APIENTRY alGetError( void );
|
rlm@0
|
394
|
rlm@0
|
395
|
rlm@0
|
396 /*
|
rlm@0
|
397 * Extension support.
|
rlm@0
|
398 * Query for the presence of an extension, and obtain any appropriate
|
rlm@0
|
399 * function pointers and enum values.
|
rlm@0
|
400 */
|
rlm@0
|
401 AL_API ALboolean AL_APIENTRY alIsExtensionPresent( const ALchar* extname );
|
rlm@0
|
402
|
rlm@0
|
403 AL_API void* AL_APIENTRY alGetProcAddress( const ALchar* fname );
|
rlm@0
|
404
|
rlm@0
|
405 AL_API ALenum AL_APIENTRY alGetEnumValue( const ALchar* ename );
|
rlm@0
|
406
|
rlm@0
|
407
|
rlm@0
|
408 /*
|
rlm@0
|
409 * LISTENER
|
rlm@0
|
410 * Listener represents the location and orientation of the
|
rlm@0
|
411 * 'user' in 3D-space.
|
rlm@0
|
412 *
|
rlm@0
|
413 * Properties include: -
|
rlm@0
|
414 *
|
rlm@0
|
415 * Gain AL_GAIN ALfloat
|
rlm@0
|
416 * Position AL_POSITION ALfloat[3]
|
rlm@0
|
417 * Velocity AL_VELOCITY ALfloat[3]
|
rlm@0
|
418 * Orientation AL_ORIENTATION ALfloat[6] (Forward then Up vectors)
|
rlm@0
|
419 */
|
rlm@0
|
420
|
rlm@0
|
421 /*
|
rlm@0
|
422 * Set Listener parameters
|
rlm@0
|
423 */
|
rlm@0
|
424 AL_API void AL_APIENTRY alListenerf( ALenum param, ALfloat value );
|
rlm@0
|
425
|
rlm@0
|
426 AL_API void AL_APIENTRY alListener3f( ALenum param, ALfloat value1, ALfloat value2, ALfloat value3 );
|
rlm@0
|
427
|
rlm@0
|
428 AL_API void AL_APIENTRY alListenerfv( ALenum param, const ALfloat* values );
|
rlm@0
|
429
|
rlm@0
|
430 AL_API void AL_APIENTRY alListeneri( ALenum param, ALint value );
|
rlm@0
|
431
|
rlm@0
|
432 AL_API void AL_APIENTRY alListener3i( ALenum param, ALint value1, ALint value2, ALint value3 );
|
rlm@0
|
433
|
rlm@0
|
434 AL_API void AL_APIENTRY alListeneriv( ALenum param, const ALint* values );
|
rlm@0
|
435
|
rlm@0
|
436 /*
|
rlm@0
|
437 * Get Listener parameters
|
rlm@0
|
438 */
|
rlm@0
|
439 AL_API void AL_APIENTRY alGetListenerf( ALenum param, ALfloat* value );
|
rlm@0
|
440
|
rlm@0
|
441 AL_API void AL_APIENTRY alGetListener3f( ALenum param, ALfloat *value1, ALfloat *value2, ALfloat *value3 );
|
rlm@0
|
442
|
rlm@0
|
443 AL_API void AL_APIENTRY alGetListenerfv( ALenum param, ALfloat* values );
|
rlm@0
|
444
|
rlm@0
|
445 AL_API void AL_APIENTRY alGetListeneri( ALenum param, ALint* value );
|
rlm@0
|
446
|
rlm@0
|
447 AL_API void AL_APIENTRY alGetListener3i( ALenum param, ALint *value1, ALint *value2, ALint *value3 );
|
rlm@0
|
448
|
rlm@0
|
449 AL_API void AL_APIENTRY alGetListeneriv( ALenum param, ALint* values );
|
rlm@0
|
450
|
rlm@0
|
451
|
rlm@0
|
452 /**
|
rlm@0
|
453 * SOURCE
|
rlm@0
|
454 * Sources represent individual sound objects in 3D-space.
|
rlm@0
|
455 * Sources take the PCM data provided in the specified Buffer,
|
rlm@0
|
456 * apply Source-specific modifications, and then
|
rlm@0
|
457 * submit them to be mixed according to spatial arrangement etc.
|
rlm@0
|
458 *
|
rlm@0
|
459 * Properties include: -
|
rlm@0
|
460 *
|
rlm@0
|
461 * Gain AL_GAIN ALfloat
|
rlm@0
|
462 * Min Gain AL_MIN_GAIN ALfloat
|
rlm@0
|
463 * Max Gain AL_MAX_GAIN ALfloat
|
rlm@0
|
464 * Position AL_POSITION ALfloat[3]
|
rlm@0
|
465 * Velocity AL_VELOCITY ALfloat[3]
|
rlm@0
|
466 * Direction AL_DIRECTION ALfloat[3]
|
rlm@0
|
467 * Head Relative Mode AL_SOURCE_RELATIVE ALint (AL_TRUE or AL_FALSE)
|
rlm@0
|
468 * Reference Distance AL_REFERENCE_DISTANCE ALfloat
|
rlm@0
|
469 * Max Distance AL_MAX_DISTANCE ALfloat
|
rlm@0
|
470 * RollOff Factor AL_ROLLOFF_FACTOR ALfloat
|
rlm@0
|
471 * Inner Angle AL_CONE_INNER_ANGLE ALint or ALfloat
|
rlm@0
|
472 * Outer Angle AL_CONE_OUTER_ANGLE ALint or ALfloat
|
rlm@0
|
473 * Cone Outer Gain AL_CONE_OUTER_GAIN ALint or ALfloat
|
rlm@0
|
474 * Pitch AL_PITCH ALfloat
|
rlm@0
|
475 * Looping AL_LOOPING ALint (AL_TRUE or AL_FALSE)
|
rlm@0
|
476 * MS Offset AL_MSEC_OFFSET ALint or ALfloat
|
rlm@0
|
477 * Byte Offset AL_BYTE_OFFSET ALint or ALfloat
|
rlm@0
|
478 * Sample Offset AL_SAMPLE_OFFSET ALint or ALfloat
|
rlm@0
|
479 * Attached Buffer AL_BUFFER ALint
|
rlm@0
|
480 * State (Query only) AL_SOURCE_STATE ALint
|
rlm@0
|
481 * Buffers Queued (Query only) AL_BUFFERS_QUEUED ALint
|
rlm@0
|
482 * Buffers Processed (Query only) AL_BUFFERS_PROCESSED ALint
|
rlm@0
|
483 */
|
rlm@0
|
484
|
rlm@0
|
485 /* Create Source objects */
|
rlm@0
|
486 AL_API void AL_APIENTRY alGenSources( ALsizei n, ALuint* sources );
|
rlm@0
|
487
|
rlm@0
|
488 /* Delete Source objects */
|
rlm@0
|
489 AL_API void AL_APIENTRY alDeleteSources( ALsizei n, const ALuint* sources );
|
rlm@0
|
490
|
rlm@0
|
491 /* Verify a handle is a valid Source */
|
rlm@0
|
492 AL_API ALboolean AL_APIENTRY alIsSource( ALuint sid );
|
rlm@0
|
493
|
rlm@0
|
494 /*
|
rlm@0
|
495 * Set Source parameters
|
rlm@0
|
496 */
|
rlm@0
|
497 AL_API void AL_APIENTRY alSourcef( ALuint sid, ALenum param, ALfloat value );
|
rlm@0
|
498
|
rlm@0
|
499 AL_API void AL_APIENTRY alSource3f( ALuint sid, ALenum param, ALfloat value1, ALfloat value2, ALfloat value3 );
|
rlm@0
|
500
|
rlm@0
|
501 AL_API void AL_APIENTRY alSourcefv( ALuint sid, ALenum param, const ALfloat* values );
|
rlm@0
|
502
|
rlm@0
|
503 AL_API void AL_APIENTRY alSourcei( ALuint sid, ALenum param, ALint value );
|
rlm@0
|
504
|
rlm@0
|
505 AL_API void AL_APIENTRY alSource3i( ALuint sid, ALenum param, ALint value1, ALint value2, ALint value3 );
|
rlm@0
|
506
|
rlm@0
|
507 AL_API void AL_APIENTRY alSourceiv( ALuint sid, ALenum param, const ALint* values );
|
rlm@0
|
508
|
rlm@0
|
509 /*
|
rlm@0
|
510 * Get Source parameters
|
rlm@0
|
511 */
|
rlm@0
|
512 AL_API void AL_APIENTRY alGetSourcef( ALuint sid, ALenum param, ALfloat* value );
|
rlm@0
|
513
|
rlm@0
|
514 AL_API void AL_APIENTRY alGetSource3f( ALuint sid, ALenum param, ALfloat* value1, ALfloat* value2, ALfloat* value3);
|
rlm@0
|
515
|
rlm@0
|
516 AL_API void AL_APIENTRY alGetSourcefv( ALuint sid, ALenum param, ALfloat* values );
|
rlm@0
|
517
|
rlm@0
|
518 AL_API void AL_APIENTRY alGetSourcei( ALuint sid, ALenum param, ALint* value );
|
rlm@0
|
519
|
rlm@0
|
520 AL_API void AL_APIENTRY alGetSource3i( ALuint sid, ALenum param, ALint* value1, ALint* value2, ALint* value3);
|
rlm@0
|
521
|
rlm@0
|
522 AL_API void AL_APIENTRY alGetSourceiv( ALuint sid, ALenum param, ALint* values );
|
rlm@0
|
523
|
rlm@0
|
524
|
rlm@0
|
525 /*
|
rlm@0
|
526 * Source vector based playback calls
|
rlm@0
|
527 */
|
rlm@0
|
528
|
rlm@0
|
529 /* Play, replay, or resume (if paused) a list of Sources */
|
rlm@0
|
530 AL_API void AL_APIENTRY alSourcePlayv( ALsizei ns, const ALuint *sids );
|
rlm@0
|
531
|
rlm@0
|
532 /* Stop a list of Sources */
|
rlm@0
|
533 AL_API void AL_APIENTRY alSourceStopv( ALsizei ns, const ALuint *sids );
|
rlm@0
|
534
|
rlm@0
|
535 /* Rewind a list of Sources */
|
rlm@0
|
536 AL_API void AL_APIENTRY alSourceRewindv( ALsizei ns, const ALuint *sids );
|
rlm@0
|
537
|
rlm@0
|
538 /* Pause a list of Sources */
|
rlm@0
|
539 AL_API void AL_APIENTRY alSourcePausev( ALsizei ns, const ALuint *sids );
|
rlm@0
|
540
|
rlm@0
|
541 /*
|
rlm@0
|
542 * Source based playback calls
|
rlm@0
|
543 */
|
rlm@0
|
544
|
rlm@0
|
545 /* Play, replay, or resume a Source */
|
rlm@0
|
546 AL_API void AL_APIENTRY alSourcePlay( ALuint sid );
|
rlm@0
|
547
|
rlm@0
|
548 /* Stop a Source */
|
rlm@0
|
549 AL_API void AL_APIENTRY alSourceStop( ALuint sid );
|
rlm@0
|
550
|
rlm@0
|
551 /* Rewind a Source (set playback postiton to beginning) */
|
rlm@0
|
552 AL_API void AL_APIENTRY alSourceRewind( ALuint sid );
|
rlm@0
|
553
|
rlm@0
|
554 /* Pause a Source */
|
rlm@0
|
555 AL_API void AL_APIENTRY alSourcePause( ALuint sid );
|
rlm@0
|
556
|
rlm@0
|
557 /*
|
rlm@0
|
558 * Source Queuing
|
rlm@0
|
559 */
|
rlm@0
|
560 AL_API void AL_APIENTRY alSourceQueueBuffers( ALuint sid, ALsizei numEntries, const ALuint *bids );
|
rlm@0
|
561
|
rlm@0
|
562 AL_API void AL_APIENTRY alSourceUnqueueBuffers( ALuint sid, ALsizei numEntries, ALuint *bids );
|
rlm@0
|
563
|
rlm@0
|
564
|
rlm@0
|
565 /**
|
rlm@0
|
566 * BUFFER
|
rlm@0
|
567 * Buffer objects are storage space for sample data.
|
rlm@0
|
568 * Buffers are referred to by Sources. One Buffer can be used
|
rlm@0
|
569 * by multiple Sources.
|
rlm@0
|
570 *
|
rlm@0
|
571 * Properties include: -
|
rlm@0
|
572 *
|
rlm@0
|
573 * Frequency (Query only) AL_FREQUENCY ALint
|
rlm@0
|
574 * Size (Query only) AL_SIZE ALint
|
rlm@0
|
575 * Bits (Query only) AL_BITS ALint
|
rlm@0
|
576 * Channels (Query only) AL_CHANNELS ALint
|
rlm@0
|
577 */
|
rlm@0
|
578
|
rlm@0
|
579 /* Create Buffer objects */
|
rlm@0
|
580 AL_API void AL_APIENTRY alGenBuffers( ALsizei n, ALuint* buffers );
|
rlm@0
|
581
|
rlm@0
|
582 /* Delete Buffer objects */
|
rlm@0
|
583 AL_API void AL_APIENTRY alDeleteBuffers( ALsizei n, const ALuint* buffers );
|
rlm@0
|
584
|
rlm@0
|
585 /* Verify a handle is a valid Buffer */
|
rlm@0
|
586 AL_API ALboolean AL_APIENTRY alIsBuffer( ALuint bid );
|
rlm@0
|
587
|
rlm@0
|
588 /* Specify the data to be copied into a buffer */
|
rlm@0
|
589 AL_API void AL_APIENTRY alBufferData( ALuint bid, ALenum format, const ALvoid* data, ALsizei size, ALsizei freq );
|
rlm@0
|
590
|
rlm@0
|
591 /*
|
rlm@0
|
592 * Set Buffer parameters
|
rlm@0
|
593 */
|
rlm@0
|
594 AL_API void AL_APIENTRY alBufferf( ALuint bid, ALenum param, ALfloat value );
|
rlm@0
|
595
|
rlm@0
|
596 AL_API void AL_APIENTRY alBuffer3f( ALuint bid, ALenum param, ALfloat value1, ALfloat value2, ALfloat value3 );
|
rlm@0
|
597
|
rlm@0
|
598 AL_API void AL_APIENTRY alBufferfv( ALuint bid, ALenum param, const ALfloat* values );
|
rlm@0
|
599
|
rlm@0
|
600 AL_API void AL_APIENTRY alBufferi( ALuint bid, ALenum param, ALint value );
|
rlm@0
|
601
|
rlm@0
|
602 AL_API void AL_APIENTRY alBuffer3i( ALuint bid, ALenum param, ALint value1, ALint value2, ALint value3 );
|
rlm@0
|
603
|
rlm@0
|
604 AL_API void AL_APIENTRY alBufferiv( ALuint bid, ALenum param, const ALint* values );
|
rlm@0
|
605
|
rlm@0
|
606 /*
|
rlm@0
|
607 * Get Buffer parameters
|
rlm@0
|
608 */
|
rlm@0
|
609 AL_API void AL_APIENTRY alGetBufferf( ALuint bid, ALenum param, ALfloat* value );
|
rlm@0
|
610
|
rlm@0
|
611 AL_API void AL_APIENTRY alGetBuffer3f( ALuint bid, ALenum param, ALfloat* value1, ALfloat* value2, ALfloat* value3);
|
rlm@0
|
612
|
rlm@0
|
613 AL_API void AL_APIENTRY alGetBufferfv( ALuint bid, ALenum param, ALfloat* values );
|
rlm@0
|
614
|
rlm@0
|
615 AL_API void AL_APIENTRY alGetBufferi( ALuint bid, ALenum param, ALint* value );
|
rlm@0
|
616
|
rlm@0
|
617 AL_API void AL_APIENTRY alGetBuffer3i( ALuint bid, ALenum param, ALint* value1, ALint* value2, ALint* value3);
|
rlm@0
|
618
|
rlm@0
|
619 AL_API void AL_APIENTRY alGetBufferiv( ALuint bid, ALenum param, ALint* values );
|
rlm@0
|
620
|
rlm@0
|
621
|
rlm@0
|
622 /*
|
rlm@0
|
623 * Global Parameters
|
rlm@0
|
624 */
|
rlm@0
|
625 AL_API void AL_APIENTRY alDopplerFactor( ALfloat value );
|
rlm@0
|
626
|
rlm@0
|
627 AL_API void AL_APIENTRY alDopplerVelocity( ALfloat value );
|
rlm@0
|
628
|
rlm@0
|
629 AL_API void AL_APIENTRY alSpeedOfSound( ALfloat value );
|
rlm@0
|
630
|
rlm@0
|
631 AL_API void AL_APIENTRY alDistanceModel( ALenum distanceModel );
|
rlm@0
|
632
|
rlm@0
|
633 /*
|
rlm@0
|
634 * Pointer-to-function types, useful for dynamically getting AL entry points.
|
rlm@0
|
635 */
|
rlm@0
|
636 typedef void (AL_APIENTRY *LPALENABLE)( ALenum capability );
|
rlm@0
|
637 typedef void (AL_APIENTRY *LPALDISABLE)( ALenum capability );
|
rlm@0
|
638 typedef ALboolean (AL_APIENTRY *LPALISENABLED)( ALenum capability );
|
rlm@0
|
639 typedef const ALchar* (AL_APIENTRY *LPALGETSTRING)( ALenum param );
|
rlm@0
|
640 typedef void (AL_APIENTRY *LPALGETBOOLEANV)( ALenum param, ALboolean* data );
|
rlm@0
|
641 typedef void (AL_APIENTRY *LPALGETINTEGERV)( ALenum param, ALint* data );
|
rlm@0
|
642 typedef void (AL_APIENTRY *LPALGETFLOATV)( ALenum param, ALfloat* data );
|
rlm@0
|
643 typedef void (AL_APIENTRY *LPALGETDOUBLEV)( ALenum param, ALdouble* data );
|
rlm@0
|
644 typedef ALboolean (AL_APIENTRY *LPALGETBOOLEAN)( ALenum param );
|
rlm@0
|
645 typedef ALint (AL_APIENTRY *LPALGETINTEGER)( ALenum param );
|
rlm@0
|
646 typedef ALfloat (AL_APIENTRY *LPALGETFLOAT)( ALenum param );
|
rlm@0
|
647 typedef ALdouble (AL_APIENTRY *LPALGETDOUBLE)( ALenum param );
|
rlm@0
|
648 typedef ALenum (AL_APIENTRY *LPALGETERROR)( void );
|
rlm@0
|
649 typedef ALboolean (AL_APIENTRY *LPALISEXTENSIONPRESENT)(const ALchar* extname );
|
rlm@0
|
650 typedef void* (AL_APIENTRY *LPALGETPROCADDRESS)( const ALchar* fname );
|
rlm@0
|
651 typedef ALenum (AL_APIENTRY *LPALGETENUMVALUE)( const ALchar* ename );
|
rlm@0
|
652 typedef void (AL_APIENTRY *LPALLISTENERF)( ALenum param, ALfloat value );
|
rlm@0
|
653 typedef void (AL_APIENTRY *LPALLISTENER3F)( ALenum param, ALfloat value1, ALfloat value2, ALfloat value3 );
|
rlm@0
|
654 typedef void (AL_APIENTRY *LPALLISTENERFV)( ALenum param, const ALfloat* values );
|
rlm@0
|
655 typedef void (AL_APIENTRY *LPALLISTENERI)( ALenum param, ALint value );
|
rlm@0
|
656 typedef void (AL_APIENTRY *LPALLISTENER3I)( ALenum param, ALint value1, ALint value2, ALint value3 );
|
rlm@0
|
657 typedef void (AL_APIENTRY *LPALLISTENERIV)( ALenum param, const ALint* values );
|
rlm@0
|
658 typedef void (AL_APIENTRY *LPALGETLISTENERF)( ALenum param, ALfloat* value );
|
rlm@0
|
659 typedef void (AL_APIENTRY *LPALGETLISTENER3F)( ALenum param, ALfloat *value1, ALfloat *value2, ALfloat *value3 );
|
rlm@0
|
660 typedef void (AL_APIENTRY *LPALGETLISTENERFV)( ALenum param, ALfloat* values );
|
rlm@0
|
661 typedef void (AL_APIENTRY *LPALGETLISTENERI)( ALenum param, ALint* value );
|
rlm@0
|
662 typedef void (AL_APIENTRY *LPALGETLISTENER3I)( ALenum param, ALint *value1, ALint *value2, ALint *value3 );
|
rlm@0
|
663 typedef void (AL_APIENTRY *LPALGETLISTENERIV)( ALenum param, ALint* values );
|
rlm@0
|
664 typedef void (AL_APIENTRY *LPALGENSOURCES)( ALsizei n, ALuint* sources );
|
rlm@0
|
665 typedef void (AL_APIENTRY *LPALDELETESOURCES)( ALsizei n, const ALuint* sources );
|
rlm@0
|
666 typedef ALboolean (AL_APIENTRY *LPALISSOURCE)( ALuint sid );
|
rlm@0
|
667 typedef void (AL_APIENTRY *LPALSOURCEF)( ALuint sid, ALenum param, ALfloat value);
|
rlm@0
|
668 typedef void (AL_APIENTRY *LPALSOURCE3F)( ALuint sid, ALenum param, ALfloat value1, ALfloat value2, ALfloat value3 );
|
rlm@0
|
669 typedef void (AL_APIENTRY *LPALSOURCEFV)( ALuint sid, ALenum param, const ALfloat* values );
|
rlm@0
|
670 typedef void (AL_APIENTRY *LPALSOURCEI)( ALuint sid, ALenum param, ALint value);
|
rlm@0
|
671 typedef void (AL_APIENTRY *LPALSOURCE3I)( ALuint sid, ALenum param, ALint value1, ALint value2, ALint value3 );
|
rlm@0
|
672 typedef void (AL_APIENTRY *LPALSOURCEIV)( ALuint sid, ALenum param, const ALint* values );
|
rlm@0
|
673 typedef void (AL_APIENTRY *LPALGETSOURCEF)( ALuint sid, ALenum param, ALfloat* value );
|
rlm@0
|
674 typedef void (AL_APIENTRY *LPALGETSOURCE3F)( ALuint sid, ALenum param, ALfloat* value1, ALfloat* value2, ALfloat* value3);
|
rlm@0
|
675 typedef void (AL_APIENTRY *LPALGETSOURCEFV)( ALuint sid, ALenum param, ALfloat* values );
|
rlm@0
|
676 typedef void (AL_APIENTRY *LPALGETSOURCEI)( ALuint sid, ALenum param, ALint* value );
|
rlm@0
|
677 typedef void (AL_APIENTRY *LPALGETSOURCE3I)( ALuint sid, ALenum param, ALint* value1, ALint* value2, ALint* value3);
|
rlm@0
|
678 typedef void (AL_APIENTRY *LPALGETSOURCEIV)( ALuint sid, ALenum param, ALint* values );
|
rlm@0
|
679 typedef void (AL_APIENTRY *LPALSOURCEPLAYV)( ALsizei ns, const ALuint *sids );
|
rlm@0
|
680 typedef void (AL_APIENTRY *LPALSOURCESTOPV)( ALsizei ns, const ALuint *sids );
|
rlm@0
|
681 typedef void (AL_APIENTRY *LPALSOURCEREWINDV)( ALsizei ns, const ALuint *sids );
|
rlm@0
|
682 typedef void (AL_APIENTRY *LPALSOURCEPAUSEV)( ALsizei ns, const ALuint *sids );
|
rlm@0
|
683 typedef void (AL_APIENTRY *LPALSOURCEPLAY)( ALuint sid );
|
rlm@0
|
684 typedef void (AL_APIENTRY *LPALSOURCESTOP)( ALuint sid );
|
rlm@0
|
685 typedef void (AL_APIENTRY *LPALSOURCEREWIND)( ALuint sid );
|
rlm@0
|
686 typedef void (AL_APIENTRY *LPALSOURCEPAUSE)( ALuint sid );
|
rlm@0
|
687 typedef void (AL_APIENTRY *LPALSOURCEQUEUEBUFFERS)(ALuint sid, ALsizei numEntries, const ALuint *bids );
|
rlm@0
|
688 typedef void (AL_APIENTRY *LPALSOURCEUNQUEUEBUFFERS)(ALuint sid, ALsizei numEntries, ALuint *bids );
|
rlm@0
|
689 typedef void (AL_APIENTRY *LPALGENBUFFERS)( ALsizei n, ALuint* buffers );
|
rlm@0
|
690 typedef void (AL_APIENTRY *LPALDELETEBUFFERS)( ALsizei n, const ALuint* buffers );
|
rlm@0
|
691 typedef ALboolean (AL_APIENTRY *LPALISBUFFER)( ALuint bid );
|
rlm@0
|
692 typedef void (AL_APIENTRY *LPALBUFFERDATA)( ALuint bid, ALenum format, const ALvoid* data, ALsizei size, ALsizei freq );
|
rlm@0
|
693 typedef void (AL_APIENTRY *LPALBUFFERF)( ALuint bid, ALenum param, ALfloat value);
|
rlm@0
|
694 typedef void (AL_APIENTRY *LPALBUFFER3F)( ALuint bid, ALenum param, ALfloat value1, ALfloat value2, ALfloat value3 );
|
rlm@0
|
695 typedef void (AL_APIENTRY *LPALBUFFERFV)( ALuint bid, ALenum param, const ALfloat* values );
|
rlm@0
|
696 typedef void (AL_APIENTRY *LPALBUFFERI)( ALuint bid, ALenum param, ALint value);
|
rlm@0
|
697 typedef void (AL_APIENTRY *LPALBUFFER3I)( ALuint bid, ALenum param, ALint value1, ALint value2, ALint value3 );
|
rlm@0
|
698 typedef void (AL_APIENTRY *LPALBUFFERIV)( ALuint bid, ALenum param, const ALint* values );
|
rlm@0
|
699 typedef void (AL_APIENTRY *LPALGETBUFFERF)( ALuint bid, ALenum param, ALfloat* value );
|
rlm@0
|
700 typedef void (AL_APIENTRY *LPALGETBUFFER3F)( ALuint bid, ALenum param, ALfloat* value1, ALfloat* value2, ALfloat* value3);
|
rlm@0
|
701 typedef void (AL_APIENTRY *LPALGETBUFFERFV)( ALuint bid, ALenum param, ALfloat* values );
|
rlm@0
|
702 typedef void (AL_APIENTRY *LPALGETBUFFERI)( ALuint bid, ALenum param, ALint* value );
|
rlm@0
|
703 typedef void (AL_APIENTRY *LPALGETBUFFER3I)( ALuint bid, ALenum param, ALint* value1, ALint* value2, ALint* value3);
|
rlm@0
|
704 typedef void (AL_APIENTRY *LPALGETBUFFERIV)( ALuint bid, ALenum param, ALint* values );
|
rlm@0
|
705 typedef void (AL_APIENTRY *LPALDOPPLERFACTOR)( ALfloat value );
|
rlm@0
|
706 typedef void (AL_APIENTRY *LPALDOPPLERVELOCITY)( ALfloat value );
|
rlm@0
|
707 typedef void (AL_APIENTRY *LPALSPEEDOFSOUND)( ALfloat value );
|
rlm@0
|
708 typedef void (AL_APIENTRY *LPALDISTANCEMODEL)( ALenum distanceModel );
|
rlm@0
|
709
|
rlm@0
|
710 #if defined(TARGET_OS_MAC) && TARGET_OS_MAC
|
rlm@0
|
711 #pragma export off
|
rlm@0
|
712 #endif
|
rlm@0
|
713
|
rlm@0
|
714 #if defined(__cplusplus)
|
rlm@0
|
715 } /* extern "C" */
|
rlm@0
|
716 #endif
|
rlm@0
|
717
|
rlm@0
|
718 #endif /* AL_AL_H */
|