diff options
author | Chris Robinson <[email protected]> | 2011-05-20 09:36:36 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2011-05-20 09:36:36 -0700 |
commit | 35a0430c8134c6a13768cd6bf7b252d24ac9e2aa (patch) | |
tree | ddc1e3d248e7a257c4534bfc12943766e2d5d38c /OpenAL32/Include | |
parent | 1b5caa4112bf76d6b046d33a65d29d94daf03f43 (diff) |
Store the separate effect parameters in a union
Diffstat (limited to 'OpenAL32/Include')
-rw-r--r-- | OpenAL32/Include/alEffect.h | 100 |
1 files changed, 50 insertions, 50 deletions
diff --git a/OpenAL32/Include/alEffect.h b/OpenAL32/Include/alEffect.h index aa8e1200..2e91c34c 100644 --- a/OpenAL32/Include/alEffect.h +++ b/OpenAL32/Include/alEffect.h @@ -1,5 +1,3 @@ -// NOTE: The effect structure is getting too large, it may be a good idea to -// start using a union or another form of unified storage. #ifndef _AL_EFFECT_H_ #define _AL_EFFECT_H_ @@ -25,54 +23,56 @@ typedef struct ALeffect // Effect type (AL_EFFECT_NULL, ...) ALenum type; - struct { - // Shared Reverb Properties - ALfloat Density; - ALfloat Diffusion; - ALfloat Gain; - ALfloat GainHF; - ALfloat DecayTime; - ALfloat DecayHFRatio; - ALfloat ReflectionsGain; - ALfloat ReflectionsDelay; - ALfloat LateReverbGain; - ALfloat LateReverbDelay; - ALfloat AirAbsorptionGainHF; - ALfloat RoomRolloffFactor; - ALboolean DecayHFLimit; - - // Additional EAX Reverb Properties - ALfloat GainLF; - ALfloat DecayLFRatio; - ALfloat ReflectionsPan[3]; - ALfloat LateReverbPan[3]; - ALfloat EchoTime; - ALfloat EchoDepth; - ALfloat ModulationTime; - ALfloat ModulationDepth; - ALfloat HFReference; - ALfloat LFReference; - } Reverb; - - struct { - ALfloat Delay; - ALfloat LRDelay; - - ALfloat Damping; - ALfloat Feedback; - - ALfloat Spread; - } Echo; - - struct { - ALfloat Frequency; - ALfloat HighPassCutoff; - ALint Waveform; - } Modulator; - - struct { - ALfloat Gain; - } Dedicated; + union { + struct { + // Shared Reverb Properties + ALfloat Density; + ALfloat Diffusion; + ALfloat Gain; + ALfloat GainHF; + ALfloat DecayTime; + ALfloat DecayHFRatio; + ALfloat ReflectionsGain; + ALfloat ReflectionsDelay; + ALfloat LateReverbGain; + ALfloat LateReverbDelay; + ALfloat AirAbsorptionGainHF; + ALfloat RoomRolloffFactor; + ALboolean DecayHFLimit; + + // Additional EAX Reverb Properties + ALfloat GainLF; + ALfloat DecayLFRatio; + ALfloat ReflectionsPan[3]; + ALfloat LateReverbPan[3]; + ALfloat EchoTime; + ALfloat EchoDepth; + ALfloat ModulationTime; + ALfloat ModulationDepth; + ALfloat HFReference; + ALfloat LFReference; + } Reverb; + + struct { + ALfloat Delay; + ALfloat LRDelay; + + ALfloat Damping; + ALfloat Feedback; + + ALfloat Spread; + } Echo; + + struct { + ALfloat Frequency; + ALfloat HighPassCutoff; + ALint Waveform; + } Modulator; + + struct { + ALfloat Gain; + } Dedicated; + } Params; // Index to itself ALuint effect; |