diff options
-rw-r--r-- | Alc/ALu.c | 9 | ||||
-rw-r--r-- | Alc/effects/null.c | 4 | ||||
-rw-r--r-- | OpenAL32/Include/alAuxEffectSlot.h | 5 | ||||
-rw-r--r-- | OpenAL32/Include/alMain.h | 6 |
4 files changed, 12 insertions, 12 deletions
@@ -1521,7 +1521,7 @@ static void ApplyStablizer(FrontStablizer *Stablizer, ALfloat (*restrict Buffer) } } -static void ApplyDistanceComp(ALfloatBUFFERSIZE *restrict Samples, DistanceComp *distcomp, +static void ApplyDistanceComp(ALfloat (*restrict Samples)[BUFFERSIZE], DistanceComp *distcomp, ALfloat *restrict Values, ALsizei SamplesToDo, ALsizei numchans) { ALsizei i, c; @@ -1564,7 +1564,7 @@ static void ApplyDistanceComp(ALfloatBUFFERSIZE *restrict Samples, DistanceComp } } -static void ApplyDither(ALfloatBUFFERSIZE *restrict Samples, ALuint *dither_seed, +static void ApplyDither(ALfloat (*restrict Samples)[BUFFERSIZE], ALuint *dither_seed, const ALfloat quant_scale, const ALsizei SamplesToDo, const ALsizei numchans) { @@ -1618,8 +1618,9 @@ DECL_TEMPLATE(ALuint, Conv_ALint, 2147483648u) #undef DECL_TEMPLATE #define DECL_TEMPLATE(T, A) \ -static void Write##A(const ALfloatBUFFERSIZE *InBuffer, ALvoid *OutBuffer, \ - ALsizei Offset, ALsizei SamplesToDo, ALsizei numchans) \ +static void Write##A(const ALfloat (*restrict InBuffer)[BUFFERSIZE], \ + ALvoid *OutBuffer, ALsizei Offset, ALsizei SamplesToDo, \ + ALsizei numchans) \ { \ ALsizei i, j; \ for(j = 0;j < numchans;j++) \ diff --git a/Alc/effects/null.c b/Alc/effects/null.c index a6591c58..f3e8a6df 100644 --- a/Alc/effects/null.c +++ b/Alc/effects/null.c @@ -17,7 +17,7 @@ typedef struct ALnullState { static ALvoid ALnullState_Destruct(ALnullState *state); static ALboolean ALnullState_deviceUpdate(ALnullState *state, ALCdevice *device); static ALvoid ALnullState_update(ALnullState *state, const ALCcontext *context, const ALeffectslot *slot, const ALeffectProps *props); -static ALvoid ALnullState_process(ALnullState *state, ALsizei samplesToDo, const ALfloatBUFFERSIZE*restrict samplesIn, ALfloatBUFFERSIZE*restrict samplesOut, ALsizei NumChannels); +static ALvoid ALnullState_process(ALnullState *state, ALsizei samplesToDo, const ALfloat (*restrict samplesIn)[BUFFERSIZE], ALfloat (*restrict samplesOut)[BUFFERSIZE], ALsizei mumChannels); static void *ALnullState_New(size_t size); static void ALnullState_Delete(void *ptr); @@ -64,7 +64,7 @@ static ALvoid ALnullState_update(ALnullState* UNUSED(state), const ALCcontext* U * input to the output buffer. The result should be added to the output buffer, * not replace it. */ -static ALvoid ALnullState_process(ALnullState* UNUSED(state), ALsizei UNUSED(samplesToDo), const ALfloatBUFFERSIZE*restrict UNUSED(samplesIn), ALfloatBUFFERSIZE*restrict UNUSED(samplesOut), ALsizei UNUSED(NumChannels)) +static ALvoid ALnullState_process(ALnullState* UNUSED(state), ALsizei UNUSED(samplesToDo), const ALfloatBUFFERSIZE*restrict UNUSED(samplesIn), ALfloatBUFFERSIZE*restrict UNUSED(samplesOut), ALsizei UNUSED(numChannels)) { } diff --git a/OpenAL32/Include/alAuxEffectSlot.h b/OpenAL32/Include/alAuxEffectSlot.h index 908c72c5..74bb841c 100644 --- a/OpenAL32/Include/alAuxEffectSlot.h +++ b/OpenAL32/Include/alAuxEffectSlot.h @@ -35,6 +35,11 @@ struct ALeffectStateVtable { void (*const Delete)(void *ptr); }; +/* Small hack to use a pointer-to-array types as a normal argument type. + * Shouldn't be used directly. + */ +typedef ALfloat ALfloatBUFFERSIZE[BUFFERSIZE]; + #define DEFINE_ALEFFECTSTATE_VTABLE(T) \ DECLARE_THUNK(T, ALeffectState, void, Destruct) \ DECLARE_THUNK1(T, ALeffectState, ALboolean, deviceUpdate, ALCdevice*) \ diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h index 10f9008a..7e954f0d 100644 --- a/OpenAL32/Include/alMain.h +++ b/OpenAL32/Include/alMain.h @@ -720,12 +720,6 @@ inline ALint GetChannelIdxByName(const RealMixParams *real, enum Channel chan) vector_al_string SearchDataFiles(const char *match, const char *subdir); -/* Small hack to use a pointer-to-array types as a normal argument type. - * Shouldn't be used directly. - */ -typedef ALfloat ALfloatBUFFERSIZE[BUFFERSIZE]; -typedef ALfloat ALfloat2[2]; - #ifdef __cplusplus } #endif |