When doing desktop share (either full screen or tab), do we need to mute the local playback?
The answer depends on the use case actually.
For example, for Google Cast, in general the sharing sender is near the receiver, and thus we expect during the Casting, the sender side no longer plays out the audio.
However, for video chat, like Hangouts, we will expect both peers can hear the sound.
Our current solution is to hard the mute/unmute in different code paths:
1. For code path chooseDesktopMedia-->getUserMedia({video:desktop, audio:desktop}), we unmute the local playback. (As we'd expect this pair of APIs are more likely to be used by WebRTC app, like Hangouts.)
2. For code path getUserMedia({video:screen, audio:system}), and tabCapture(), we mute the local playback. (As we'd expect these APIs are more likely to be used by Cast)
But technically, there may not be a relation between the use case and which APIs to call. This setting would bring inconvenience to app developer.
Thus to resolve it, we need to add one entry for audio constraint, so that the app developer can specify in the getUserMedia or tabCapture API call whether his app would mute or unmute local playback during capturing.
Comment 1 by qiangchen@chromium.org
, Sep 27 2016