efx.h 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738
  1. #ifndef __efx_h_
  2. #define __efx_h_
  3. #ifdef __cplusplus
  4. extern "C" {
  5. #endif
  6. #define ALC_EXT_EFX_NAME "ALC_EXT_EFX"
  7. /**
  8. * Context definitions to be used with alcCreateContext.
  9. * These values must be unique and not conflict with other
  10. * al context values.
  11. */
  12. #define ALC_EFX_MAJOR_VERSION 0x20001
  13. #define ALC_EFX_MINOR_VERSION 0x20002
  14. #define ALC_MAX_AUXILIARY_SENDS 0x20003
  15. /**
  16. * Listener definitions to be used with alListener functions.
  17. * These values must be unique and not conflict with other
  18. * al listener values.
  19. */
  20. #define AL_METERS_PER_UNIT 0x20004
  21. /**
  22. * Source definitions to be used with alSource functions.
  23. * These values must be unique and not conflict with other
  24. * al source values.
  25. */
  26. #define AL_DIRECT_FILTER 0x20005
  27. #define AL_AUXILIARY_SEND_FILTER 0x20006
  28. #define AL_AIR_ABSORPTION_FACTOR 0x20007
  29. #define AL_ROOM_ROLLOFF_FACTOR 0x20008
  30. #define AL_CONE_OUTER_GAINHF 0x20009
  31. #define AL_DIRECT_FILTER_GAINHF_AUTO 0x2000A
  32. #define AL_AUXILIARY_SEND_FILTER_GAIN_AUTO 0x2000B
  33. #define AL_AUXILIARY_SEND_FILTER_GAINHF_AUTO 0x2000C
  34. /**
  35. * Effect object definitions to be used with alEffect functions.
  36. *
  37. * Effect parameter value definitions, ranges, and defaults
  38. * appear farther down in this file.
  39. */
  40. /* Reverb Parameters */
  41. #define AL_REVERB_DENSITY 0x0001
  42. #define AL_REVERB_DIFFUSION 0x0002
  43. #define AL_REVERB_GAIN 0x0003
  44. #define AL_REVERB_GAINHF 0x0004
  45. #define AL_REVERB_DECAY_TIME 0x0005
  46. #define AL_REVERB_DECAY_HFRATIO 0x0006
  47. #define AL_REVERB_REFLECTIONS_GAIN 0x0007
  48. #define AL_REVERB_REFLECTIONS_DELAY 0x0008
  49. #define AL_REVERB_LATE_REVERB_GAIN 0x0009
  50. #define AL_REVERB_LATE_REVERB_DELAY 0x000A
  51. #define AL_REVERB_AIR_ABSORPTION_GAINHF 0x000B
  52. #define AL_REVERB_ROOM_ROLLOFF_FACTOR 0x000C
  53. #define AL_REVERB_DECAY_HFLIMIT 0x000D
  54. /* Chorus Parameters */
  55. #define AL_CHORUS_WAVEFORM 0x0001
  56. #define AL_CHORUS_PHASE 0x0002
  57. #define AL_CHORUS_RATE 0x0003
  58. #define AL_CHORUS_DEPTH 0x0004
  59. #define AL_CHORUS_FEEDBACK 0x0005
  60. #define AL_CHORUS_DELAY 0x0006
  61. /* Distortion Parameters */
  62. #define AL_DISTORTION_EDGE 0x0001
  63. #define AL_DISTORTION_GAIN 0x0002
  64. #define AL_DISTORTION_LOWPASS_CUTOFF 0x0003
  65. #define AL_DISTORTION_EQCENTER 0x0004
  66. #define AL_DISTORTION_EQBANDWIDTH 0x0005
  67. /* Echo Parameters */
  68. #define AL_ECHO_DELAY 0x0001
  69. #define AL_ECHO_LRDELAY 0x0002
  70. #define AL_ECHO_DAMPING 0x0003
  71. #define AL_ECHO_FEEDBACK 0x0004
  72. #define AL_ECHO_SPREAD 0x0005
  73. /* Flanger Parameters */
  74. #define AL_FLANGER_WAVEFORM 0x0001
  75. #define AL_FLANGER_PHASE 0x0002
  76. #define AL_FLANGER_RATE 0x0003
  77. #define AL_FLANGER_DEPTH 0x0004
  78. #define AL_FLANGER_FEEDBACK 0x0005
  79. #define AL_FLANGER_DELAY 0x0006
  80. /* Frequencyshifter Parameters */
  81. #define AL_FREQUENCY_SHIFTER_FREQUENCY 0x0001
  82. #define AL_FREQUENCY_SHIFTER_LEFT_DIRECTION 0x0002
  83. #define AL_FREQUENCY_SHIFTER_RIGHT_DIRECTION 0x0003
  84. /* Vocalmorpher Parameters */
  85. #define AL_VOCAL_MORPHER_PHONEMEA 0x0001
  86. #define AL_VOCAL_MORPHER_PHONEMEA_COARSE_TUNING 0x0002
  87. #define AL_VOCAL_MORPHER_PHONEMEB 0x0003
  88. #define AL_VOCAL_MORPHER_PHONEMEB_COARSE_TUNING 0x0004
  89. #define AL_VOCAL_MORPHER_WAVEFORM 0x0005
  90. #define AL_VOCAL_MORPHER_RATE 0x0006
  91. /* Pitchshifter Parameters */
  92. #define AL_PITCH_SHIFTER_COARSE_TUNE 0x0001
  93. #define AL_PITCH_SHIFTER_FINE_TUNE 0x0002
  94. /* Ringmodulator Parameters */
  95. #define AL_RING_MODULATOR_FREQUENCY 0x0001
  96. #define AL_RING_MODULATOR_HIGHPASS_CUTOFF 0x0002
  97. #define AL_RING_MODULATOR_WAVEFORM 0x0003
  98. /* Autowah Parameters */
  99. #define AL_AUTOWAH_ATTACK_TIME 0x0001
  100. #define AL_AUTOWAH_RELEASE_TIME 0x0002
  101. #define AL_AUTOWAH_RESONANCE 0x0003
  102. #define AL_AUTOWAH_PEAK_GAIN 0x0004
  103. /* Compressor Parameters */
  104. #define AL_COMPRESSOR_ONOFF 0x0001
  105. /* Equalizer Parameters */
  106. #define AL_EQUALIZER_LOW_GAIN 0x0001
  107. #define AL_EQUALIZER_LOW_CUTOFF 0x0002
  108. #define AL_EQUALIZER_MID1_GAIN 0x0003
  109. #define AL_EQUALIZER_MID1_CENTER 0x0004
  110. #define AL_EQUALIZER_MID1_WIDTH 0x0005
  111. #define AL_EQUALIZER_MID2_GAIN 0x0006
  112. #define AL_EQUALIZER_MID2_CENTER 0x0007
  113. #define AL_EQUALIZER_MID2_WIDTH 0x0008
  114. #define AL_EQUALIZER_HIGH_GAIN 0x0009
  115. #define AL_EQUALIZER_HIGH_CUTOFF 0x000A
  116. /* Effect type */
  117. #define AL_EFFECT_FIRST_PARAMETER 0x0000
  118. #define AL_EFFECT_LAST_PARAMETER 0x8000
  119. #define AL_EFFECT_TYPE 0x8001
  120. /* Effect type definitions to be used with AL_EFFECT_TYPE. */
  121. #define AL_EFFECT_NULL 0x0000 /* Can also be used as an Effect Object ID */
  122. #define AL_EFFECT_REVERB 0x0001
  123. #define AL_EFFECT_CHORUS 0x0002
  124. #define AL_EFFECT_DISTORTION 0x0003
  125. #define AL_EFFECT_ECHO 0x0004
  126. #define AL_EFFECT_FLANGER 0x0005
  127. #define AL_EFFECT_FREQUENCY_SHIFTER 0x0006
  128. #define AL_EFFECT_VOCAL_MORPHER 0x0007
  129. #define AL_EFFECT_PITCH_SHIFTER 0x0008
  130. #define AL_EFFECT_RING_MODULATOR 0x0009
  131. #define AL_EFFECT_AUTOWAH 0x000A
  132. #define AL_EFFECT_COMPRESSOR 0x000B
  133. #define AL_EFFECT_EQUALIZER 0x000C
  134. /**
  135. * Auxiliary Slot object definitions to be used with alAuxiliaryEffectSlot functions.
  136. */
  137. #define AL_EFFECTSLOT_EFFECT 0x0001
  138. #define AL_EFFECTSLOT_GAIN 0x0002
  139. #define AL_EFFECTSLOT_AUXILIARY_SEND_AUTO 0x0003
  140. /**
  141. * Value to be used as an Auxiliary Slot ID to disable a source send..
  142. */
  143. #define AL_EFFECTSLOT_NULL 0x0000
  144. /**
  145. * Filter object definitions to be used with alFilter functions.
  146. */
  147. /* Lowpass parameters. */
  148. #define AL_LOWPASS_GAIN 0x0001
  149. #define AL_LOWPASS_GAINHF 0x0002
  150. /* Highpass Parameters */
  151. #define AL_HIGHPASS_GAIN 0x0001
  152. #define AL_HIGHPASS_GAINLF 0x0002
  153. /* Bandpass Parameters */
  154. #define AL_BANDPASS_GAIN 0x0001
  155. #define AL_BANDPASS_GAINLF 0x0002
  156. #define AL_BANDPASS_GAINHF 0x0003
  157. /* Filter type */
  158. #define AL_FILTER_FIRST_PARAMETER 0x0000
  159. #define AL_FILTER_LAST_PARAMETER 0x8000
  160. #define AL_FILTER_TYPE 0x8001
  161. /* Filter type definitions to be used with AL_FILTER_TYPE. */
  162. #define AL_FILTER_NULL 0x0000 /* Can also be used as a Filter Object ID */
  163. #define AL_FILTER_LOWPASS 0x0001
  164. #define AL_FILTER_HIGHPASS 0x0002
  165. #define AL_FILTER_BANDPASS 0x0003
  166. /**
  167. * Effect object functions.
  168. */
  169. /* Create Effect objects. */
  170. typedef void (__cdecl *LPALGENEFFECTS)( ALsizei n, ALuint* effects );
  171. /* Delete Effect objects. */
  172. typedef void (__cdecl *LPALDELETEEFFECTS)( ALsizei n, ALuint* effects );
  173. /* Verify a handle is a valid Effect. */
  174. typedef ALboolean (__cdecl *LPALISEFFECT)( ALuint eid );
  175. /* Set an integer parameter for an Effect object. */
  176. typedef void (__cdecl *LPALEFFECTI)( ALuint eid, ALenum param, ALint value);
  177. typedef void (__cdecl *LPALEFFECTIV)( ALuint eid, ALenum param, ALint* values );
  178. /* Set a floating point parameter for an Effect object. */
  179. typedef void (__cdecl *LPALEFFECTF)( ALuint eid, ALenum param, ALfloat value);
  180. typedef void (__cdecl *LPALEFFECTFV)( ALuint eid, ALenum param, ALfloat* values );
  181. /* Get an integer parameter for an Effect object. */
  182. typedef void (__cdecl *LPALGETEFFECTI)( ALuint eid, ALenum pname, ALint* value );
  183. typedef void (__cdecl *LPALGETEFFECTIV)( ALuint eid, ALenum pname, ALint* values );
  184. /* Get a floating point parameter for an Effect object. */
  185. typedef void (__cdecl *LPALGETEFFECTF)( ALuint eid, ALenum pname, ALfloat* value );
  186. typedef void (__cdecl *LPALGETEFFECTFV)( ALuint eid, ALenum pname, ALfloat* values );
  187. /**
  188. * Filter object functions
  189. */
  190. /* Create Filter objects. */
  191. typedef void (__cdecl *LPALGENFILTERS)( ALsizei n, ALuint* filters );
  192. /* Delete Filter objects. */
  193. typedef void (__cdecl *LPALDELETEFILTERS)( ALsizei n, ALuint* filters );
  194. /* Verify a handle is a valid Filter. */
  195. typedef ALboolean (__cdecl *LPALISFILTER)( ALuint fid );
  196. /* Set an integer parameter for a Filter object. */
  197. typedef void (__cdecl *LPALFILTERI)( ALuint fid, ALenum param, ALint value );
  198. typedef void (__cdecl *LPALFILTERIV)( ALuint fid, ALenum param, ALint* values );
  199. /* Set a floating point parameter for an Filter object. */
  200. typedef void (__cdecl *LPALFILTERF)( ALuint fid, ALenum param, ALfloat value);
  201. typedef void (__cdecl *LPALFILTERFV)( ALuint fid, ALenum param, ALfloat* values );
  202. /* Get an integer parameter for a Filter object. */
  203. typedef void (__cdecl *LPALGETFILTERI)( ALuint fid, ALenum pname, ALint* value );
  204. typedef void (__cdecl *LPALGETFILTERIV)( ALuint fid, ALenum pname, ALint* values );
  205. /* Get a floating point parameter for a Filter object. */
  206. typedef void (__cdecl *LPALGETFILTERF)( ALuint fid, ALenum pname, ALfloat* value );
  207. typedef void (__cdecl *LPALGETFILTERFV)( ALuint fid, ALenum pname, ALfloat* values );
  208. /**
  209. * Auxiliary Slot object functions
  210. */
  211. /* Create Auxiliary Slot objects. */
  212. typedef void (__cdecl *LPALGENAUXILIARYEFFECTSLOTS)( ALsizei n, ALuint* slots );
  213. /* Delete Auxiliary Slot objects. */
  214. typedef void (__cdecl *LPALDELETEAUXILIARYEFFECTSLOTS)( ALsizei n, ALuint* slots );
  215. /* Verify a handle is a valid Auxiliary Slot. */
  216. typedef ALboolean (__cdecl *LPALISAUXILIARYEFFECTSLOT)( ALuint slot );
  217. /* Set an integer parameter for a Auxiliary Slot object. */
  218. typedef void (__cdecl *LPALAUXILIARYEFFECTSLOTI)( ALuint asid, ALenum param, ALint value );
  219. typedef void (__cdecl *LPALAUXILIARYEFFECTSLOTIV)( ALuint asid, ALenum param, ALint* values );
  220. /* Set a floating point parameter for an Auxiliary Slot object. */
  221. typedef void (__cdecl *LPALAUXILIARYEFFECTSLOTF)( ALuint asid, ALenum param, ALfloat value );
  222. typedef void (__cdecl *LPALAUXILIARYEFFECTSLOTFV)( ALuint asid, ALenum param, ALfloat* values );
  223. /* Get an integer parameter for a Auxiliary Slot object. */
  224. typedef void (__cdecl *LPALGETAUXILIARYEFFECTSLOTI)( ALuint asid, ALenum pname, ALint* value );
  225. typedef void (__cdecl *LPALGETAUXILIARYEFFECTSLOTIV)( ALuint asid, ALenum pname, ALint* values );
  226. /* Get a floating point parameter for a Auxiliary Slot object. */
  227. typedef void (__cdecl *LPALGETAUXILIARYEFFECTSLOTF)( ALuint asid, ALenum pname, ALfloat* value );
  228. typedef void (__cdecl *LPALGETAUXILIARYEFFECTSLOTFV)( ALuint asid, ALenum pname, ALfloat* values );
  229. /**********************************************************
  230. * Filter ranges and defaults.
  231. */
  232. /**
  233. * Lowpass filter
  234. */
  235. #define LOWPASS_MIN_GAIN 0.0f
  236. #define LOWPASS_MAX_GAIN 1.0f
  237. #define LOWPASS_DEFAULT_GAIN 1.0f
  238. #define LOWPASS_MIN_GAINHF 0.0f
  239. #define LOWPASS_MAX_GAINHF 1.0f
  240. #define LOWPASS_DEFAULT_GAINHF 1.0f
  241. /**
  242. * Highpass filter
  243. */
  244. #define HIGHPASS_MIN_GAIN 0.0f
  245. #define HIGHPASS_MAX_GAIN 1.0f
  246. #define HIGHPASS_DEFAULT_GAIN 1.0f
  247. #define HIGHPASS_MIN_GAINLF 0.0f
  248. #define HIGHPASS_MAX_GAINLF 1.0f
  249. #define HIGHPASS_DEFAULT_GAINLF 1.0f
  250. /**
  251. * Bandpass filter
  252. */
  253. #define BANDPASS_MIN_GAIN 0.0f
  254. #define BANDPASS_MAX_GAIN 1.0f
  255. #define BANDPASS_DEFAULT_GAIN 1.0f
  256. #define BANDPASS_MIN_GAINHF 0.0f
  257. #define BANDPASS_MAX_GAINHF 1.0f
  258. #define BANDPASS_DEFAULT_GAINHF 1.0f
  259. #define BANDPASS_MIN_GAINLF 0.0f
  260. #define BANDPASS_MAX_GAINLF 1.0f
  261. #define BANDPASS_DEFAULT_GAINLF 1.0f
  262. /**********************************************************
  263. * Effect parameter structures, value definitions, ranges and defaults.
  264. */
  265. /**
  266. * AL reverb effect parameter ranges and defaults
  267. */
  268. #define AL_REVERB_MIN_DENSITY 0.0f
  269. #define AL_REVERB_MAX_DENSITY 1.0f
  270. #define AL_REVERB_DEFAULT_DENSITY 1.0f
  271. #define AL_REVERB_MIN_DIFFUSION 0.0f
  272. #define AL_REVERB_MAX_DIFFUSION 1.0f
  273. #define AL_REVERB_DEFAULT_DIFFUSION 1.0f
  274. #define AL_REVERB_MIN_GAIN 0.0f
  275. #define AL_REVERB_MAX_GAIN 1.0f
  276. #define AL_REVERB_DEFAULT_GAIN 0.32f
  277. #define AL_REVERB_MIN_GAINHF 0.0f
  278. #define AL_REVERB_MAX_GAINHF 1.0f
  279. #define AL_REVERB_DEFAULT_GAINHF 0.89f
  280. #define AL_REVERB_MIN_DECAY_TIME 0.1f
  281. #define AL_REVERB_MAX_DECAY_TIME 20.0f
  282. #define AL_REVERB_DEFAULT_DECAY_TIME 1.49f
  283. #define AL_REVERB_MIN_DECAY_HFRATIO 0.1f
  284. #define AL_REVERB_MAX_DECAY_HFRATIO 2.0f
  285. #define AL_REVERB_DEFAULT_DECAY_HFRATIO 0.83f
  286. #define AL_REVERB_MIN_REFLECTIONS_GAIN 0.0f
  287. #define AL_REVERB_MAX_REFLECTIONS_GAIN 3.16f
  288. #define AL_REVERB_DEFAULT_REFLECTIONS_GAIN 0.05f
  289. #define AL_REVERB_MIN_REFLECTIONS_DELAY 0.0f
  290. #define AL_REVERB_MAX_REFLECTIONS_DELAY 0.3f
  291. #define AL_REVERB_DEFAULT_REFLECTIONS_DELAY 0.007f
  292. #define AL_REVERB_MIN_LATE_REVERB_GAIN 0.0f
  293. #define AL_REVERB_MAX_LATE_REVERB_GAIN 10.0f
  294. #define AL_REVERB_DEFAULT_LATE_REVERB_GAIN 1.26f
  295. #define AL_REVERB_MIN_LATE_REVERB_DELAY 0.0f
  296. #define AL_REVERB_MAX_LATE_REVERB_DELAY 0.1f
  297. #define AL_REVERB_DEFAULT_LATE_REVERB_DELAY 0.011f
  298. #define AL_REVERB_MIN_AIR_ABSORPTION_GAINHF 0.892f
  299. #define AL_REVERB_MAX_AIR_ABSORPTION_GAINHF 1.0f
  300. #define AL_REVERB_DEFAULT_AIR_ABSORPTION_GAINHF 0.994f
  301. #define AL_REVERB_MIN_ROOM_ROLLOFF_FACTOR 0.0f
  302. #define AL_REVERB_MAX_ROOM_ROLLOFF_FACTOR 10.0f
  303. #define AL_REVERB_DEFAULT_ROOM_ROLLOFF_FACTOR 0.0f
  304. #define AL_REVERB_MIN_DECAY_HFLIMIT AL_FALSE
  305. #define AL_REVERB_MAX_DECAY_HFLIMIT AL_TRUE
  306. #define AL_REVERB_DEFAULT_DECAY_HFLIMIT AL_TRUE
  307. /**
  308. * AL chorus effect parameter ranges and defaults
  309. */
  310. #define AL_CHORUS_MIN_WAVEFORM 0
  311. #define AL_CHORUS_MAX_WAVEFORM 1
  312. #define AL_CHORUS_DEFAULT_WAVEFORM 1
  313. #define AL_CHORUS_WAVEFORM_SINUSOID 0
  314. #define AL_CHORUS_WAVEFORM_TRIANGLE 1
  315. #define AL_CHORUS_MIN_PHASE (-180)
  316. #define AL_CHORUS_MAX_PHASE 180
  317. #define AL_CHORUS_DEFAULT_PHASE 90
  318. #define AL_CHORUS_MIN_RATE 0.0f
  319. #define AL_CHORUS_MAX_RATE 10.0f
  320. #define AL_CHORUS_DEFAULT_RATE 1.1f
  321. #define AL_CHORUS_MIN_DEPTH 0.0f
  322. #define AL_CHORUS_MAX_DEPTH 1.0f
  323. #define AL_CHORUS_DEFAULT_DEPTH 0.1f
  324. #define AL_CHORUS_MIN_FEEDBACK (-1.0f)
  325. #define AL_CHORUS_MAX_FEEDBACK 1.0f
  326. #define AL_CHORUS_DEFAULT_FEEDBACK 0.25f
  327. #define AL_CHORUS_MIN_DELAY 0.0f
  328. #define AL_CHORUS_MAX_DELAY 0.016f
  329. #define AL_CHORUS_DEFAULT_DELAY 0.016f
  330. /**
  331. * AL distortion effect parameter ranges and defaults
  332. */
  333. #define AL_DISTORTION_MIN_EDGE 0.0f
  334. #define AL_DISTORTION_MAX_EDGE 1.0f
  335. #define AL_DISTORTION_DEFAULT_EDGE 0.2f
  336. #define AL_DISTORTION_MIN_GAIN 0.01f
  337. #define AL_DISTORTION_MAX_GAIN 1.0f
  338. #define AL_DISTORTION_DEFAULT_GAIN 0.05f
  339. #define AL_DISTORTION_MIN_LOWPASS_CUTOFF 80.0f
  340. #define AL_DISTORTION_MAX_LOWPASS_CUTOFF 24000.0f
  341. #define AL_DISTORTION_DEFAULT_LOWPASS_CUTOFF 8000.0f
  342. #define AL_DISTORTION_MIN_EQCENTER 80.0f
  343. #define AL_DISTORTION_MAX_EQCENTER 24000.0f
  344. #define AL_DISTORTION_DEFAULT_EQCENTER 3600.0f
  345. #define AL_DISTORTION_MIN_EQBANDWIDTH 80.0f
  346. #define AL_DISTORTION_MAX_EQBANDWIDTH 24000.0f
  347. #define AL_DISTORTION_DEFAULT_EQBANDWIDTH 3600.0f
  348. /**
  349. * AL echo effect parameter ranges and defaults
  350. */
  351. #define AL_ECHO_MIN_DELAY 0.0f
  352. #define AL_ECHO_MAX_DELAY 0.207f
  353. #define AL_ECHO_DEFAULT_DELAY 0.1f
  354. #define AL_ECHO_MIN_LRDELAY 0.0f
  355. #define AL_ECHO_MAX_LRDELAY 0.404f
  356. #define AL_ECHO_DEFAULT_LRDELAY 0.1f
  357. #define AL_ECHO_MIN_DAMPING 0.0f
  358. #define AL_ECHO_MAX_DAMPING 0.99f
  359. #define AL_ECHO_DEFAULT_DAMPING 0.5f
  360. #define AL_ECHO_MIN_FEEDBACK 0.0f
  361. #define AL_ECHO_MAX_FEEDBACK 1.0f
  362. #define AL_ECHO_DEFAULT_FEEDBACK 0.5f
  363. #define AL_ECHO_MIN_SPREAD (-1.0f)
  364. #define AL_ECHO_MAX_SPREAD 1.0f
  365. #define AL_ECHO_DEFAULT_SPREAD (-1.0f)
  366. /**
  367. * AL flanger effect parameter ranges and defaults
  368. */
  369. #define AL_FLANGER_MIN_WAVEFORM 0
  370. #define AL_FLANGER_MAX_WAVEFORM 1
  371. #define AL_FLANGER_DEFAULT_WAVEFORM 1
  372. #define AL_FLANGER_WAVEFORM_SINUSOID 0
  373. #define AL_FLANGER_WAVEFORM_TRIANGLE 1
  374. #define AL_FLANGER_MIN_PHASE (-180)
  375. #define AL_FLANGER_MAX_PHASE 180
  376. #define AL_FLANGER_DEFAULT_PHASE 0
  377. #define AL_FLANGER_MIN_RATE 0.0f
  378. #define AL_FLANGER_MAX_RATE 10.0f
  379. #define AL_FLANGER_DEFAULT_RATE 0.27f
  380. #define AL_FLANGER_MIN_DEPTH 0.0f
  381. #define AL_FLANGER_MAX_DEPTH 1.0f
  382. #define AL_FLANGER_DEFAULT_DEPTH 1.0f
  383. #define AL_FLANGER_MIN_FEEDBACK (-1.0f)
  384. #define AL_FLANGER_MAX_FEEDBACK 1.0f
  385. #define AL_FLANGER_DEFAULT_FEEDBACK (-0.5f)
  386. #define AL_FLANGER_MIN_DELAY 0.0f
  387. #define AL_FLANGER_MAX_DELAY 0.004f
  388. #define AL_FLANGER_DEFAULT_DELAY 0.002f
  389. /**
  390. * AL frequency shifter effect parameter ranges and defaults
  391. */
  392. #define AL_FREQUENCY_SHIFTER_MIN_FREQUENCY 0.0f
  393. #define AL_FREQUENCY_SHIFTER_MAX_FREQUENCY 24000.0f
  394. #define AL_FREQUENCY_SHIFTER_DEFAULT_FREQUENCY 0.0f
  395. #define AL_FREQUENCY_SHIFTER_MIN_LEFT_DIRECTION 0
  396. #define AL_FREQUENCY_SHIFTER_MAX_LEFT_DIRECTION 2
  397. #define AL_FREQUENCY_SHIFTER_DEFAULT_LEFT_DIRECTION 0
  398. #define AL_FREQUENCY_SHIFTER_MIN_RIGHT_DIRECTION 0
  399. #define AL_FREQUENCY_SHIFTER_MAX_RIGHT_DIRECTION 2
  400. #define AL_FREQUENCY_SHIFTER_DEFAULT_RIGHT_DIRECTION 0
  401. #define AL_FREQUENCY_SHIFTER_DIRECTION_DOWN 0
  402. #define AL_FREQUENCY_SHIFTER_DIRECTION_UP 1
  403. #define AL_FREQUENCY_SHIFTER_DIRECTION_OFF 2
  404. /**
  405. * AL vocal morpher effect parameter ranges and defaults
  406. */
  407. #define AL_VOCAL_MORPHER_MIN_PHONEMEA 0
  408. #define AL_VOCAL_MORPHER_MAX_PHONEMEA 29
  409. #define AL_VOCAL_MORPHER_DEFAULT_PHONEMEA 0
  410. #define AL_VOCAL_MORPHER_MIN_PHONEMEA_COARSE_TUNING (-24)
  411. #define AL_VOCAL_MORPHER_MAX_PHONEMEA_COARSE_TUNING 24
  412. #define AL_VOCAL_MORPHER_DEFAULT_PHONEMEA_COARSE_TUNING 0
  413. #define AL_VOCAL_MORPHER_MIN_PHONEMEB 0
  414. #define AL_VOCAL_MORPHER_MAX_PHONEMEB 29
  415. #define AL_VOCAL_MORPHER_DEFAULT_PHONEMEB 10
  416. #define AL_VOCAL_MORPHER_PHONEME_A 0
  417. #define AL_VOCAL_MORPHER_PHONEME_E 1
  418. #define AL_VOCAL_MORPHER_PHONEME_I 2
  419. #define AL_VOCAL_MORPHER_PHONEME_O 3
  420. #define AL_VOCAL_MORPHER_PHONEME_U 4
  421. #define AL_VOCAL_MORPHER_PHONEME_AA 5
  422. #define AL_VOCAL_MORPHER_PHONEME_AE 6
  423. #define AL_VOCAL_MORPHER_PHONEME_AH 7
  424. #define AL_VOCAL_MORPHER_PHONEME_AO 8
  425. #define AL_VOCAL_MORPHER_PHONEME_EH 9
  426. #define AL_VOCAL_MORPHER_PHONEME_ER 10
  427. #define AL_VOCAL_MORPHER_PHONEME_IH 11
  428. #define AL_VOCAL_MORPHER_PHONEME_IY 12
  429. #define AL_VOCAL_MORPHER_PHONEME_UH 13
  430. #define AL_VOCAL_MORPHER_PHONEME_UW 14
  431. #define AL_VOCAL_MORPHER_PHONEME_B 15
  432. #define AL_VOCAL_MORPHER_PHONEME_D 16
  433. #define AL_VOCAL_MORPHER_PHONEME_F 17
  434. #define AL_VOCAL_MORPHER_PHONEME_G 18
  435. #define AL_VOCAL_MORPHER_PHONEME_J 19
  436. #define AL_VOCAL_MORPHER_PHONEME_K 20
  437. #define AL_VOCAL_MORPHER_PHONEME_L 21
  438. #define AL_VOCAL_MORPHER_PHONEME_M 22
  439. #define AL_VOCAL_MORPHER_PHONEME_N 23
  440. #define AL_VOCAL_MORPHER_PHONEME_P 24
  441. #define AL_VOCAL_MORPHER_PHONEME_R 25
  442. #define AL_VOCAL_MORPHER_PHONEME_S 26
  443. #define AL_VOCAL_MORPHER_PHONEME_T 27
  444. #define AL_VOCAL_MORPHER_PHONEME_V 28
  445. #define AL_VOCAL_MORPHER_PHONEME_Z 29
  446. #define AL_VOCAL_MORPHER_MIN_PHONEMEB_COARSE_TUNING (-24)
  447. #define AL_VOCAL_MORPHER_MAX_PHONEMEB_COARSE_TUNING 24
  448. #define AL_VOCAL_MORPHER_DEFAULT_PHONEMEB_COARSE_TUNING 0
  449. #define AL_VOCAL_MORPHER_MIN_WAVEFORM 0
  450. #define AL_VOCAL_MORPHER_MAX_WAVEFORM 2
  451. #define AL_VOCAL_MORPHER_DEFAULT_WAVEFORM 0
  452. #define AL_VOCAL_MORPHER_WAVEFORM_SINUSOID 0
  453. #define AL_VOCAL_MORPHER_WAVEFORM_TRIANGLE 1
  454. #define AL_VOCAL_MORPHER_WAVEFORM_SAWTOOTH 2
  455. #define AL_VOCAL_MORPHER_MIN_RATE 0.0f
  456. #define AL_VOCAL_MORPHER_MAX_RATE 10.0f
  457. #define AL_VOCAL_MORPHER_DEFAULT_RATE 1.41f
  458. /**
  459. * AL pitch shifter effect parameter ranges and defaults
  460. */
  461. #define AL_PITCH_SHIFTER_MIN_COARSE_TUNE (-12)
  462. #define AL_PITCH_SHIFTER_MAX_COARSE_TUNE 12
  463. #define AL_PITCH_SHIFTER_DEFAULT_COARSE_TUNE 12
  464. #define AL_PITCH_SHIFTER_MIN_FINE_TUNE (-50)
  465. #define AL_PITCH_SHIFTER_MAX_FINE_TUNE 50
  466. #define AL_PITCH_SHIFTER_DEFAULT_FINE_TUNE 0
  467. /**
  468. * AL ring modulator effect parameter ranges and defaults
  469. */
  470. #define AL_RING_MODULATOR_MIN_FREQUENCY 0.0f
  471. #define AL_RING_MODULATOR_MAX_FREQUENCY 8000.0f
  472. #define AL_RING_MODULATOR_DEFAULT_FREQUENCY 440.0f
  473. #define AL_RING_MODULATOR_MIN_HIGHPASS_CUTOFF 0.0f
  474. #define AL_RING_MODULATOR_MAX_HIGHPASS_CUTOFF 24000.0f
  475. #define AL_RING_MODULATOR_DEFAULT_HIGHPASS_CUTOFF 800.0f
  476. #define AL_RING_MODULATOR_MIN_WAVEFORM 0
  477. #define AL_RING_MODULATOR_MAX_WAVEFORM 2
  478. #define AL_RING_MODULATOR_DEFAULT_WAVEFORM 0
  479. #define AL_RING_MODULATOR_SINUSOID 0
  480. #define AL_RING_MODULATOR_SAWTOOTH 1
  481. #define AL_RING_MODULATOR_SQUARE 2
  482. /**
  483. * AL autowah effect parameter ranges and defaults
  484. */
  485. #define AL_AUTOWAH_MIN_ATTACK_TIME 0.0001f
  486. #define AL_AUTOWAH_MAX_ATTACK_TIME 1.0f
  487. #define AL_AUTOWAH_DEFAULT_ATTACK_TIME 0.06f
  488. #define AL_AUTOWAH_MIN_RELEASE_TIME 0.0001f
  489. #define AL_AUTOWAH_MAX_RELEASE_TIME 1.0f
  490. #define AL_AUTOWAH_DEFAULT_RELEASE_TIME 0.06f
  491. #define AL_AUTOWAH_MIN_RESONANCE 2.0f
  492. #define AL_AUTOWAH_MAX_RESONANCE 1000.0f
  493. #define AL_AUTOWAH_DEFAULT_RESONANCE 1000.0f
  494. #define AL_AUTOWAH_MIN_PEAK_GAIN 0.00003f
  495. #define AL_AUTOWAH_MAX_PEAK_GAIN 31621.0f
  496. #define AL_AUTOWAH_DEFAULT_PEAK_GAIN 11.22f
  497. /**
  498. * AL compressor effect parameter ranges and defaults
  499. */
  500. #define AL_COMPRESSOR_MIN_ONOFF 0
  501. #define AL_COMPRESSOR_MAX_ONOFF 1
  502. #define AL_COMPRESSOR_DEFAULT_ONOFF 1
  503. /**
  504. * AL equalizer effect parameter ranges and defaults
  505. */
  506. #define AL_EQUALIZER_MIN_LOW_GAIN 0.126f
  507. #define AL_EQUALIZER_MAX_LOW_GAIN 7.943f
  508. #define AL_EQUALIZER_DEFAULT_LOW_GAIN 1.0f
  509. #define AL_EQUALIZER_MIN_LOW_CUTOFF 50.0f
  510. #define AL_EQUALIZER_MAX_LOW_CUTOFF 800.0f
  511. #define AL_EQUALIZER_DEFAULT_LOW_CUTOFF 200.0f
  512. #define AL_EQUALIZER_MIN_MID1_GAIN 0.126f
  513. #define AL_EQUALIZER_MAX_MID1_GAIN 7.943f
  514. #define AL_EQUALIZER_DEFAULT_MID1_GAIN 1.0f
  515. #define AL_EQUALIZER_MIN_MID1_CENTER 200.0f
  516. #define AL_EQUALIZER_MAX_MID1_CENTER 3000.0f
  517. #define AL_EQUALIZER_DEFAULT_MID1_CENTER 500.0f
  518. #define AL_EQUALIZER_MIN_MID1_WIDTH 0.01f
  519. #define AL_EQUALIZER_MAX_MID1_WIDTH 1.0f
  520. #define AL_EQUALIZER_DEFAULT_MID1_WIDTH 1.0f
  521. #define AL_EQUALIZER_MIN_MID2_GAIN 0.126f
  522. #define AL_EQUALIZER_MAX_MID2_GAIN 7.943f
  523. #define AL_EQUALIZER_DEFAULT_MID2_GAIN 1.0f
  524. #define AL_EQUALIZER_MIN_MID2_CENTER 1000.0f
  525. #define AL_EQUALIZER_MAX_MID2_CENTER 8000.0f
  526. #define AL_EQUALIZER_DEFAULT_MID2_CENTER 3000.0f
  527. #define AL_EQUALIZER_MIN_MID2_WIDTH 0.01f
  528. #define AL_EQUALIZER_MAX_MID2_WIDTH 1.0f
  529. #define AL_EQUALIZER_DEFAULT_MID2_WIDTH 1.0f
  530. #define AL_EQUALIZER_MIN_HIGH_GAIN 0.126f
  531. #define AL_EQUALIZER_MAX_HIGH_GAIN 7.943f
  532. #define AL_EQUALIZER_DEFAULT_HIGH_GAIN 1.0f
  533. #define AL_EQUALIZER_MIN_HIGH_CUTOFF 4000.0f
  534. #define AL_EQUALIZER_MAX_HIGH_CUTOFF 16000.0f
  535. #define AL_EQUALIZER_DEFAULT_HIGH_CUTOFF 6000.0f
  536. /**********************************************************
  537. * Source parameter value definitions, ranges and defaults.
  538. */
  539. #define AL_MIN_AIR_ABSORPTION_FACTOR 0.0f
  540. #define AL_MAX_AIR_ABSORPTION_FACTOR 10.0f
  541. #define AL_DEFAULT_AIR_ABSORPTION_FACTOR 0.0f
  542. #define AL_MIN_ROOM_ROLLOFF_FACTOR 0.0f
  543. #define AL_MAX_ROOM_ROLLOFF_FACTOR 10.0f
  544. #define AL_DEFAULT_ROOM_ROLLOFF_FACTOR 0.0f
  545. #define AL_MIN_CONE_OUTER_GAINHF 0.0f
  546. #define AL_MAX_CONE_OUTER_GAINHF 1.0f
  547. #define AL_DEFAULT_CONE_OUTER_GAINHF 1.0f
  548. #define AL_MIN_DIRECT_FILTER_GAINHF_AUTO AL_FALSE
  549. #define AL_MAX_DIRECT_FILTER_GAINHF_AUTO AL_TRUE
  550. #define AL_DEFAULT_DIRECT_FILTER_GAINHF_AUTO AL_TRUE
  551. #define AL_MIN_AUXILIARY_SEND_FILTER_GAIN_AUTO AL_FALSE
  552. #define AL_MAX_AUXILIARY_SEND_FILTER_GAIN_AUTO AL_TRUE
  553. #define AL_DEFAULT_AUXILIARY_SEND_FILTER_GAIN_AUTO AL_TRUE
  554. #define AL_MIN_AUXILIARY_SEND_FILTER_GAINHF_AUTO AL_FALSE
  555. #define AL_MAX_AUXILIARY_SEND_FILTER_GAINHF_AUTO AL_TRUE
  556. #define AL_DEFAULT_AUXILIARY_SEND_FILTER_GAINHF_AUTO AL_TRUE
  557. /**********************************************************
  558. * Listener parameter value definitions, ranges and defaults.
  559. */
  560. #define AL_MIN_METERS_PER_UNIT FLT_MIN
  561. #define AL_MAX_METERS_PER_UNIT FLT_MAX
  562. #define AL_DEFAULT_METERS_PER_UNIT 1.0f
  563. #ifdef __cplusplus
  564. } /* extern "C" */
  565. #endif
  566. #endif /* __efx_h_ */