Avoid using a variable for array sizes and const variable initialization
This commit is contained in:
+5
-5
@@ -192,17 +192,17 @@ DECL_TEMPLATE(ALubyte, cubic8)
|
||||
#undef DECL_TEMPLATE
|
||||
|
||||
|
||||
#define DECL_TEMPLATE(T, count, sampler) \
|
||||
static void Mix_##T##_##count##_##sampler(ALsource *Source, ALCdevice *Device,\
|
||||
#define DECL_TEMPLATE(T, chnct, sampler) \
|
||||
static void Mix_##T##_##chnct##_##sampler(ALsource *Source, ALCdevice *Device,\
|
||||
const T *data, ALuint *DataPosInt, ALuint *DataPosFrac, \
|
||||
ALuint OutPos, ALuint SamplesToDo, ALuint BufferSize) \
|
||||
{ \
|
||||
const ALuint Channels = count; \
|
||||
const ALfloat scaler = 1.0f/Channels; \
|
||||
const ALuint Channels = chnct; \
|
||||
const ALfloat scaler = 1.0f/chnct; \
|
||||
ALfloat (*DryBuffer)[MAXCHANNELS]; \
|
||||
ALfloat *ClickRemoval, *PendingClicks; \
|
||||
ALuint pos, frac; \
|
||||
ALfloat DrySend[Channels][MAXCHANNELS]; \
|
||||
ALfloat DrySend[chnct][MAXCHANNELS]; \
|
||||
FILTER *DryFilter; \
|
||||
ALuint BufferIdx; \
|
||||
ALuint increment; \
|
||||
|
||||
Reference in New Issue
Block a user