Skip to content

Support overriding and remapping audio channels in AudioServer #105934

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

BuzzLord
Copy link

Adds support (via project settings under audio/buses/channel_override) to the AudioServer to change the speaker mode (i.e. number of channels) that Godot uses internally, independent of the audio driver used. It can be used to test more channels (e.g. 7.1 surround when using a stereo audio setup), or fewer channels (e.g. stereo when using a 7.1 surround setup). This is intended to be used to help troubleshoot audio issues when testing with different speaker setups.

This PR also adds the ability to remap internal channels onto different output channels of the audio device. For example, you can remap the rear or side stereo channels of a 7.1 surround system into the front channels of a stereo system in order to verify the audio is correct.

This is a extension of, and replacement for #105682. Like that PR, this feature makes it possible for Godot developers without the necessary surround sound peripheral to reproduce bugs and review fixes to issues that are the result of an unanticipated number of channels, such as: #92532

Channel Override Settings

Channel Override Audio Bus

BuzzLord added 2 commits May 16, 2025 07:43
Add support (via project settings) to AudioServer to change the number of channels
that Godot uses internally, independent of the audio driver used.
Also added the ability to remap internal channels onto different output channels of the audio device.

This is intended to be used to help troubleshoot audio issues when testing with different
speaker setups.
Removed the override flag, changed speaker_mode to allow taking a 'Default' value
(to correspond to using the audio driver speaker_mode). Moved the setting to
audio/general.

Removed the channel remap settings from project settings, and made configuring them
done through exposed methods on AudioServer (get/set_channel_remap).
@BuzzLord BuzzLord force-pushed the audio-server-override-channels branch from f93e0fa to de3521e Compare May 16, 2025 13:43
@BuzzLord
Copy link
Author

BuzzLord commented May 16, 2025

Updated based on the feedback from the most recent audio team meeting. I left the new commit as is for now (i.e. didn't --amend), to make it clear what I changed. I'll rebase and squash it into one commit once its done.

I also made a little project to help show off the functionality.

test-godot-channel-override.zip

SpeakerMode

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants