| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "media/audio/audio_input_controller.h" | 5 #include "media/audio/audio_input_controller.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/metrics/histogram_macros.h" |
| 8 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
| 9 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
| 10 #include "base/threading/thread_restrictions.h" | 11 #include "base/threading/thread_restrictions.h" |
| 11 #include "base/time/time.h" | 12 #include "base/time/time.h" |
| 12 #include "media/audio/audio_parameters.h" | 13 #include "media/audio/audio_parameters.h" |
| 13 #include "media/base/scoped_histogram_timer.h" | |
| 14 #include "media/base/user_input_monitor.h" | 14 #include "media/base/user_input_monitor.h" |
| 15 | 15 |
| 16 using base::TimeDelta; | 16 using base::TimeDelta; |
| 17 | 17 |
| 18 namespace { | 18 namespace { |
| 19 | 19 |
| 20 const int kMaxInputChannels = 3; | 20 const int kMaxInputChannels = 3; |
| 21 | 21 |
| 22 // TODO(henrika): remove usage of timers and add support for proper | 22 // TODO(henrika): remove usage of timers and add support for proper |
| 23 // notification of when the input device is removed. This was originally added | 23 // notification of when the input device is removed. This was originally added |
| (...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 669 } | 669 } |
| 670 | 670 |
| 671 void AudioInputController::LogSilenceState(SilenceState value) { | 671 void AudioInputController::LogSilenceState(SilenceState value) { |
| 672 UMA_HISTOGRAM_ENUMERATION("Media.AudioInputControllerSessionSilenceReport", | 672 UMA_HISTOGRAM_ENUMERATION("Media.AudioInputControllerSessionSilenceReport", |
| 673 value, | 673 value, |
| 674 SILENCE_STATE_MAX + 1); | 674 SILENCE_STATE_MAX + 1); |
| 675 } | 675 } |
| 676 #endif | 676 #endif |
| 677 | 677 |
| 678 } // namespace media | 678 } // namespace media |
| OLD | NEW |