Repository navigation
Restore audio mute on navigation - #540
Conversation
|
Hmm, this issue is strange on multiple fronts. Firstly, we already set muted audio during the creation of the CEF browser window. This should be respected for the lifetime of the CefBrowser, and the load state of the CefFrame shouldn't affect it (a CefBrowser can contain multiple CefFrames) . obs-browser/obs-browser-source.cpp Lines 238 to 239 in a162443 However, without your change, adding the following to OnLoadEnd always returns "unmuted", even when audio is very clearly muted. blog(OG_WARNING, "OnLoadEnd: %s", browser->GetHost()->IsAudioMuted() ? "muted" : "unmuted");With your change, it correctly returns "muted" and the momentary audio does not occur. To me, this very much sounds like a CEF bug when combining windowless rendering with an audio handler. I can confirm this PR fixes the issue, though I fear it is a bit hacky. |
|
A follow-up from some of my own testing:
My hope was that either one of these would be "better suited" than in the load handler. Unfortunately, this proved incorrect - they have the same behaviour as our existing implementation of calling |
Restore audio muting in OnLoadStart when Control audio via OBS is enabled to prevent audio from bypassing OBS monitoring.
b0a2f1a to
bee24d3
Compare
|
@WizardCM ok, made that change + the one I mentioned off thread. |
|
I can confirm this fixes the issue as presented, though I have no insight if this is the "correct" fix or just a hack as mentioned. As a chore task, we should see if this has been reported upstream if we think it's an upstream issue, and report it if there isn't a report already. |
|
@Fenrirthviti yes agreed, Matt mentioned he would take care of this in his comment on the related issue obsproject/obs-studio#13985 (comment) |
Description
Restore audio muting in OnLoadStart when control audio via OBS is enabled to prevent audio from bypassing OBS monitoring.
Related docs:
https://cef-builds.spotifycdn.com/docs/150.0/classCefLoadHandler.html#a830e338ec7d37d6fa50576311f965f31
https://cef-builds.spotifycdn.com/docs/150.0/classCefBrowserHost.html#a153d179c9ff202c8bb8869d2e9a820a2
Motivation and Context
Bug reported in OBS v33 beta 5,
Fixes obsproject/obs-studio#13985
LLM used to help me navigate through CEF docs but code/PR written by myself.
How Has This Been Tested?
Able to reproduce the issue with user provided alerts on v33 beta 5, no longer able to repro after these changes.
Types of changes
Checklist: