aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32
diff options
context:
space:
mode:
Diffstat (limited to 'OpenAL32')
-rw-r--r--OpenAL32/Include/alFilter.h14
-rw-r--r--OpenAL32/Include/alSource.h6
2 files changed, 7 insertions, 13 deletions
diff --git a/OpenAL32/Include/alFilter.h b/OpenAL32/Include/alFilter.h
index 09cef93c..94feb3ee 100644
--- a/OpenAL32/Include/alFilter.h
+++ b/OpenAL32/Include/alFilter.h
@@ -11,16 +11,12 @@ extern "C" {
typedef struct {
ALfloat coeff;
-#ifndef _MSC_VER
- ALfloat history[0];
-#else
- ALfloat history[1];
-#endif
+ ALfloat history[2];
} FILTER;
-static __inline ALfloat lpFilter2P(FILTER *iir, ALuint offset, ALfloat input)
+static __inline ALfloat lpFilter2P(FILTER *iir, ALfloat input)
{
- ALfloat *history = &iir->history[offset*2];
+ ALfloat *history = iir->history;
ALfloat a = iir->coeff;
ALfloat output = input;
@@ -32,9 +28,9 @@ static __inline ALfloat lpFilter2P(FILTER *iir, ALuint offset, ALfloat input)
return output;
}
-static __inline ALfloat lpFilter2PC(const FILTER *iir, ALuint offset, ALfloat input)
+static __inline ALfloat lpFilter2PC(const FILTER *iir, ALfloat input)
{
- const ALfloat *history = &iir->history[offset*2];
+ const ALfloat *history = iir->history;
ALfloat a = iir->coeff;
ALfloat output = input;
diff --git a/OpenAL32/Include/alSource.h b/OpenAL32/Include/alSource.h
index d8ffc9aa..bd1b2931 100644
--- a/OpenAL32/Include/alSource.h
+++ b/OpenAL32/Include/alSource.h
@@ -62,8 +62,7 @@ typedef struct DirectParams {
ALfloat Gains[MaxChannels][MaxChannels];
/* A low-pass filter, using 2 chained one-pole filters. */
- FILTER iirFilter;
- ALfloat history[MaxChannels*2];
+ FILTER Filter[MaxChannels];
} DirectParams;
typedef struct SendParams {
@@ -74,8 +73,7 @@ typedef struct SendParams {
ALfloat Gain;
/* A low-pass filter, using 2 chained one-pole filters. */
- FILTER iirFilter;
- ALfloat history[MaxChannels*2];
+ FILTER Filter[MaxChannels];
} SendParams;