ADM2 for Windows is based on the CoreAudioUtil class in Chrome.
CoreAudioUtil in Chrome does not use a special string to identify
the Default Communication device but instead a combination of a
string (Default) and a role parameter [1].
When CoreAudioUtil was ported to WebRTC, I accidentally added an
invalid usage of a unique string to identify the default comm device
and it can lead to errors since there are then two different ways to
identify this device. It will also complicate life when we want to
merge changes from Chrome into WebRTC.
This CL removes usage of AudioDeviceName::kDefaultCommunicationsDeviceId
in WebRTC to reduce the risk of errors.
[1] https://cs.chromium.org/chromium/src/media/audio/win/core_audio_util_win.cc?q=core_audio_ut&sq=package:chromium&g=0&l=464
Excluding flaky bot win_x86_msvc_dbg and using Tbr.
Tbr: thaloun@chromium.org
No-Try: True
Bug: webrtc:11107
Change-Id: Ie6687adbe9c3940a217456e4025967f71d86214c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/160047
Commit-Queue: Henrik Andreassson <henrika@webrtc.org>
Reviewed-by: Henrik Andreassson <henrika@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29848}
This CL is a manual spin-off of [1], which tried to apply clang-tidy's
performance-move-const-arg [1] to the WebRTC codebase.
Since there were some wrong fixes to correct, this CL lands a few
different fixes, like adding a constructor overload to take an rvalue
reference or remove 'const' to make std::move effective.
[1] - https://webrtc-review.googlesource.com/c/src/+/120350
[2] - https://clang.llvm.org/extra/clang-tidy/checks/performance-move-const-arg.html
Bug: webrtc:10252
Change-Id: I42a777247fee2cb788efcd7c2035148330056b7a
Reviewed-on: https://webrtc-review.googlesource.com/c/120928
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26553}