alEffect.h 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. // NOTE: The effect structure is getting too large, it may be a good idea to
  2. // start using a union or another form of unified storage.
  3. #ifndef _AL_EFFECT_H_
  4. #define _AL_EFFECT_H_
  5. #include "AL/al.h"
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif
  9. enum {
  10. EAXREVERB = 0,
  11. REVERB,
  12. ECHO,
  13. MODULATOR,
  14. MAX_EFFECTS
  15. };
  16. extern ALboolean DisabledEffects[MAX_EFFECTS];
  17. typedef struct ALeffect
  18. {
  19. // Effect type (AL_EFFECT_NULL, ...)
  20. ALenum type;
  21. struct {
  22. // Shared Reverb Properties
  23. ALfloat Density;
  24. ALfloat Diffusion;
  25. ALfloat Gain;
  26. ALfloat GainHF;
  27. ALfloat DecayTime;
  28. ALfloat DecayHFRatio;
  29. ALfloat ReflectionsGain;
  30. ALfloat ReflectionsDelay;
  31. ALfloat LateReverbGain;
  32. ALfloat LateReverbDelay;
  33. ALfloat AirAbsorptionGainHF;
  34. ALfloat RoomRolloffFactor;
  35. ALboolean DecayHFLimit;
  36. // Additional EAX Reverb Properties
  37. ALfloat GainLF;
  38. ALfloat DecayLFRatio;
  39. ALfloat ReflectionsPan[3];
  40. ALfloat LateReverbPan[3];
  41. ALfloat EchoTime;
  42. ALfloat EchoDepth;
  43. ALfloat ModulationTime;
  44. ALfloat ModulationDepth;
  45. ALfloat HFReference;
  46. ALfloat LFReference;
  47. } Reverb;
  48. struct {
  49. ALfloat Delay;
  50. ALfloat LRDelay;
  51. ALfloat Damping;
  52. ALfloat Feedback;
  53. ALfloat Spread;
  54. } Echo;
  55. struct {
  56. ALfloat Frequency;
  57. ALfloat HighPassCutoff;
  58. ALint Waveform;
  59. } Modulator;
  60. // Index to itself
  61. ALuint effect;
  62. } ALeffect;
  63. ALvoid ReleaseALEffects(ALCdevice *device);
  64. #ifdef __cplusplus
  65. }
  66. #endif
  67. #endif