-
-
Notifications
You must be signed in to change notification settings - Fork 21.2k
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
Confusing docs about AudioServer.set_device
#58096
Comments
The audio driver can't be changed at run-time, as Godot does not have a way to restart the audio server without restarting the entire project. Implementing this is likely nontrivial, but it would also allow for changing the output latency without restarting the project. |
I see, so that Makes more sense about why it's not working then. It would be great to be able to do this, as from the code I linked above, a temporary (in-editor rather than command line) workaround to all those issues would be simple to implement in GDscript, compared to complex in C++. |
Actually, This is why setting it to |
Hi @Calinou I think there is some misunderstanding. I think this statement is what I was looking for with this issue:
This bug is more about the |
AudioServer.set_device
does not work in the editorProjectSettings["audio/driver"] = "dummy"
does not work in the editor
ProjectSettings["audio/driver"] = "dummy"
does not work in the editorProjectSettings["audio/driver"]
does not work in the editor (no way to change audio driver)
Most project settings are not designed to be changed at run-time, as their value is not read continuously by the engine (doing this is slow). Instead, you should use server methods (like AudioServer's), and there is no such method exposed yet. There is no bug here, just missing functionality. You should open a feature proposal 🙂 |
I see, shall we close this issue then, or revert to the set_device and use as a documentation bug? |
You can keep this issue open as a documentation issue. |
ProjectSettings["audio/driver"]
does not work in the editor (no way to change audio driver)AudioServer.set_device
Godot version
3.4.2.stable
System information
Mac OSX (Intel 2019)
Issue description
I was trying to fix some of the CPU usage caused by coreaudio running non-stop while the editor runs.
Associated issues & PRs
#38154
#55608
#38208
#45948
Here is the plugin I was working on
https://github.com/tavurth/godot-sound-disabler
What's not working
Steps to reproduce
Please see above, sample code can be found here
https://github.com/tavurth/godot-sound-disabler
Minimal reproduction project
https://github.com/tavurth/godot-sound-disabler
The text was updated successfully, but these errors were encountered: