Page 1 of 1

Can cef remove the muted audio source?

PostPosted: Tue Jul 09, 2019 3:28 am
by tangyuwu
I use CEF to record audio by loading a webpage in server. I find there are two audio sources is mute or its' audio value is zero. I think it is waste for the computer. Because it take a lots of CPU time . I want to know whether there is way to close the audio source or tell CEF to stop processe it?

16:13:36(221) OnAudioStreamStarted audio_stream_id=1 sr=44100 chns=2

16:13:36(221) OnAudioStreamStarted audio_stream_id=2 sr=44100 chns=2

16:13:36(251) OnAudioStreamStarted audio_stream_id=3 sr=44100 chns=2

Re: Can cef remove the muted audio source?

PostPosted: Tue Jul 09, 2019 6:04 am
by ndesktop
You can either set audio.src = ""; or use js to delete audio element directly from DOM.

Re: Can cef remove the muted audio source?

PostPosted: Tue Jul 09, 2019 8:36 pm
by tangyuwu
Thank you very much. I try it.