diff options
author | henrika <henrika@chromium.org> | 2014-10-16 07:44:12 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-10-16 14:44:37 +0000 |
commit | c569d98674f56fccf39c53f7ec7a63127755390f (patch) | |
tree | 12bc496f1bf71c5c9421f492c63bd8f600682a88 /media/audio/alsa | |
parent | 15a8709fe24ebb55e15ed88b306d76ad72412931 (diff) | |
download | chromium_src-c569d98674f56fccf39c53f7ec7a63127755390f.zip chromium_src-c569d98674f56fccf39c53f7ec7a63127755390f.tar.gz chromium_src-c569d98674f56fccf39c53f7ec7a63127755390f.tar.bz2 |
Add support for audio input mute detection on all platforms.
TBR=rkc@chromium.org
BUG=422275
TEST=Manual tests using DVLOGs to confirm valid microphone mute states.
Review URL: https://codereview.chromium.org/645923002
Cr-Commit-Position: refs/heads/master@{#299891}
Diffstat (limited to 'media/audio/alsa')
-rw-r--r-- | media/audio/alsa/alsa_input.cc | 4 | ||||
-rw-r--r-- | media/audio/alsa/alsa_input.h | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/media/audio/alsa/alsa_input.cc b/media/audio/alsa/alsa_input.cc index 0bc9f31..3c555a0 100644 --- a/media/audio/alsa/alsa_input.cc +++ b/media/audio/alsa/alsa_input.cc @@ -336,6 +336,10 @@ double AlsaPcmInputStream::GetVolume() { return static_cast<double>(current_volume); } +bool AlsaPcmInputStream::IsMuted() { + return false; +} + void AlsaPcmInputStream::HandleError(const char* method, int error) { LOG(WARNING) << method << ": " << wrapper_->StrError(error); callback_->OnError(this); diff --git a/media/audio/alsa/alsa_input.h b/media/audio/alsa/alsa_input.h index adc2619..ef7cb2c 100644 --- a/media/audio/alsa/alsa_input.h +++ b/media/audio/alsa/alsa_input.h @@ -49,6 +49,7 @@ class AlsaPcmInputStream : public AgcAudioStream<AudioInputStream> { virtual double GetMaxVolume() override; virtual void SetVolume(double volume) override; virtual double GetVolume() override; + virtual bool IsMuted() override; private: // Logs the error and invokes any registered callbacks. |