Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(708)

Unified Diff: media/audio/win/audio_low_latency_input_win.h

Issue 155863003: Add basic support for "googDucking" to getUserMedia on Windows. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Initialize enumeration flag in constructor Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/audio/audio_parameters.h ('k') | media/audio/win/audio_low_latency_input_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/win/audio_low_latency_input_win.h
diff --git a/media/audio/win/audio_low_latency_input_win.h b/media/audio/win/audio_low_latency_input_win.h
index 99e1604925a6c05a17f855fc0fa10c7d51971e29..f8309156e16adfa9c8073323b89ae01b6a400e7c 100644
--- a/media/audio/win/audio_low_latency_input_win.h
+++ b/media/audio/win/audio_low_latency_input_win.h
@@ -88,6 +88,7 @@ class MEDIA_EXPORT WASAPIAudioInputStream
WASAPIAudioInputStream(AudioManagerWin* manager,
const AudioParameters& params,
const std::string& device_id);
+
// The dtor is typically called by the AudioManager only and it is usually
// triggered by calling AudioInputStream::Close().
virtual ~WASAPIAudioInputStream();
@@ -101,16 +102,11 @@ class MEDIA_EXPORT WASAPIAudioInputStream
virtual void SetVolume(double volume) OVERRIDE;
virtual double GetVolume() OVERRIDE;
- // Retrieves the sample rate used by the audio engine for its internal
- // processing/mixing of shared-mode streams given a specifed device.
- static int HardwareSampleRate(const std::string& device_id);
-
- // Retrieves the number of audio channels used by the audio engine for its
- // internal processing/mixing of shared-mode streams given a specified device.
- static uint32 HardwareChannelCount(const std::string& device_id);
-
bool started() const { return started_; }
+ // Returns the default hardware audio parameters of the specific device.
+ static AudioParameters GetInputStreamParameters(const std::string& device_id);
+
private:
// DelegateSimpleThread::Delegate implementation.
virtual void Run() OVERRIDE;
@@ -157,6 +153,9 @@ class MEDIA_EXPORT WASAPIAudioInputStream
// Length of the audio endpoint buffer.
uint32 endpoint_buffer_size_frames_;
+ // A copy of the supplied AudioParameter's |effects|.
+ const int effects_;
+
// Contains the unique name of the selected endpoint device.
// Note that AudioManagerBase::kDefaultDeviceId represents the default
// device role and is not a valid ID as such.
@@ -178,7 +177,7 @@ class MEDIA_EXPORT WASAPIAudioInputStream
// An IMMDevice interface which represents an audio endpoint device.
base::win::ScopedComPtr<IMMDevice> endpoint_device_;
- // Windows Audio Session API (WASAP) interfaces.
+ // Windows Audio Session API (WASAPI) interfaces.
// An IAudioClient interface which enables a client to create and initialize
// an audio stream between an audio application and the audio engine.
« no previous file with comments | « media/audio/audio_parameters.h ('k') | media/audio/win/audio_low_latency_input_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698