New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cellAudio: Fix audio channel order #11066
Conversation
Documentation says the order is Front L, Front R, Center, LFE, Surround L, Surround R, Rear L, Rear R
This pull request seems incomplete. |
The following code might be correct. |
The PCM samples games put into the buffer definitely have the order I specified above, so the names should stay like this. out_buffer names should be swapped too if you don't like my solution. Xaudio2's default channel order is L, R, C, LFE, RL, RR, SL, SR (https://docs.microsoft.com/en-us/windows/win32/xaudio2/xaudio2-default-channel-mapping) Same with OpenAL (page 141: https://www.openal.org/documentation/OpenAL_Programmers_Guide.pdf) For PulseAudio the same order is manually specified rpcs3/rpcs3/Emu/Audio/Pulse/PulseBackend.cpp Lines 36 to 66 in 78bcb0f
No clue about ALSA but the output was wrong there too. I guess you could do the swapping in the backends instead, there seems to be manual channel mapping support in all of them. |
The thing is, I wrote some of that code and I couldn't believe that the channels were swapped. Anyway, good job finding the issue (maybe they were typos). |
Documentation says samples have the order Front L, Front R, Center, LFE, Surround L, Surround R, Rear L, Rear R
Fixes #5818