diff options
author | Chris Robinson <[email protected]> | 2017-04-11 12:06:57 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2017-04-11 12:06:57 -0700 |
commit | 46046f9caa2f9014d70c0f8553ada6dafa16c1e9 (patch) | |
tree | 65c21e716e740de8eddaa482e535fcbeb5727aaa | |
parent | 05531fbee465e364fdbe5aa2c32e2c57e8f988b5 (diff) |
Remove an unnecessary variable
-rw-r--r-- | Alc/converter.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/Alc/converter.c b/Alc/converter.c index fa51f2f4..38d51d47 100644 --- a/Alc/converter.c +++ b/Alc/converter.c @@ -361,20 +361,16 @@ void DestroyChannelConverter(ChannelConverter **converter) #define DECL_TEMPLATE(T) \ static void Mono2Stereo##T(ALfloat *restrict dst, const T *src, ALsizei frames)\ { \ - const T *data = (T*)src; \ ALsizei i; \ - \ for(i = 0;i < frames;i++) \ - dst[i*2 + 1] = dst[i*2 + 0] = Sample_##T(data[i]) * 0.707106781187f; \ + dst[i*2 + 1] = dst[i*2 + 0] = Sample_##T(src[i]) * 0.707106781187f; \ } \ \ static void Stereo2Mono##T(ALfloat *restrict dst, const T *src, ALsizei frames)\ { \ - const T *data = (T*)src; \ ALsizei i; \ - \ for(i = 0;i < frames;i++) \ - dst[i] = (Sample_##T(data[i*2 + 0])+Sample_##T(data[i*2 + 1])) * \ + dst[i] = (Sample_##T(src[i*2 + 0])+Sample_##T(src[i*2 + 1])) * \ 0.707106781187f; \ } |