diff options
author | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-11 03:07:19 +0000 |
---|---|---|
committer | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-11 03:07:19 +0000 |
commit | 9ade381f46175dead00a1cc9ffc3328230e8c982 (patch) | |
tree | 64c6caf04643408b2e25bce192f03c9b7b93eaa2 /media/audio/fake_audio_output_stream.h | |
parent | adc19c0eeac9f3caaae4e35bd64e79e6b6e72a0f (diff) | |
download | chromium_src-9ade381f46175dead00a1cc9ffc3328230e8c982.zip chromium_src-9ade381f46175dead00a1cc9ffc3328230e8c982.tar.gz chromium_src-9ade381f46175dead00a1cc9ffc3328230e8c982.tar.bz2 |
Simplified AudioOutputStream interface.
1. Removed packet_size parameter from Open().
2. Removed OnClose() from the callback. Now the callback is guaranteed to be called only between Start() and Stop().
3. Added samples_per_packet in the AudioParameters struct.
BUG=39825
TEST=Unittests
Review URL: http://codereview.chromium.org/4661001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@65766 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/audio/fake_audio_output_stream.h')
-rw-r--r-- | media/audio/fake_audio_output_stream.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/media/audio/fake_audio_output_stream.h b/media/audio/fake_audio_output_stream.h index 35aed2a..5d80a8e 100644 --- a/media/audio/fake_audio_output_stream.h +++ b/media/audio/fake_audio_output_stream.h @@ -13,13 +13,14 @@ #include "base/scoped_ptr.h" #include "media/audio/audio_io.h" +#include "media/audio/audio_parameters.h" class FakeAudioOutputStream : public AudioOutputStream { public: - static AudioOutputStream* MakeFakeStream(); + static AudioOutputStream* MakeFakeStream(AudioParameters params); static FakeAudioOutputStream* GetLastFakeStream(); - virtual bool Open(uint32 packet_size); + virtual bool Open(); virtual void Start(AudioSourceCallback* callback); virtual void Stop(); virtual void SetVolume(double volume); @@ -30,7 +31,7 @@ class FakeAudioOutputStream : public AudioOutputStream { double volume() { return volume_; } private: - FakeAudioOutputStream(); + explicit FakeAudioOutputStream(AudioParameters params); virtual ~FakeAudioOutputStream(); static void DestroyLastFakeStream(void* param); |