Chromium Code Reviews| Index: content/renderer/media/audio_input_device.h |
| diff --git a/content/renderer/media/audio_input_device.h b/content/renderer/media/audio_input_device.h |
| index ed855548fbaa3dea40fad0eceda59c633ea51f89..4bff6dca3654fe21573041c1e92602ad0f2f6f40 100644 |
| --- a/content/renderer/media/audio_input_device.h |
| +++ b/content/renderer/media/audio_input_device.h |
| @@ -95,7 +95,8 @@ class CONTENT_EXPORT AudioInputDevice |
| public: |
| virtual void Capture(const std::vector<float*>& audio_data, |
| size_t number_of_frames, |
| - size_t audio_delay_milliseconds) = 0; |
| + size_t audio_delay_milliseconds, |
| + double volume) = 0; |
| virtual void OnCaptureError() = 0; |
| protected: |
| virtual ~CaptureCallback() {} |
| @@ -144,6 +145,10 @@ class CONTENT_EXPORT AudioInputDevice |
| // Returns |true| on success. |
| bool GetVolume(double* volume); |
| + // Sets the Automatic Gain Control state to on or off. |
| + // TODO(henrika): extend the comments here... |
|
tommi (sloooow) - chröme
2012/03/16 13:31:05
ping (or just remove the todo)
scherkus (not reviewing)
2012/03/20 13:49:41
ping again! :P
henrika (OOO until Aug 14)
2012/03/21 10:16:04
Much better now ;-)
|
| + void SetAutomaticGainControl(bool enabled); |
| + |
| double sample_rate() const { return audio_parameters_.sample_rate; } |
| size_t buffer_size() const { return audio_parameters_.samples_per_packet; } |
| @@ -166,6 +171,7 @@ class CONTENT_EXPORT AudioInputDevice |
| void StartOnIOThread(); |
| void ShutDownOnIOThread(); |
| void SetVolumeOnIOThread(double volume); |
| + void SetAutomaticGainControlOnIOThread(bool enabled); |
| void Send(IPC::Message* message); |
| @@ -196,6 +202,10 @@ class CONTENT_EXPORT AudioInputDevice |
| // callback. Only modified on the IO thread. |
| bool pending_device_ready_; |
| + // Stores the Automatic Gain Control state. Default is false. |
| + // Only modified on the IO thread. |
| + bool agc_is_enabled_; |
| + |
| // Our audio thread callback class. See source file for details. |
| class AudioThreadCallback; |