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

Unified Diff: media/audio/sounds/audio_stream_handler.h

Issue 1453233002: Improve input handling for WaveAudioHandler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Update FileSource Created 5 years, 1 month 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
Index: media/audio/sounds/audio_stream_handler.h
diff --git a/media/audio/sounds/audio_stream_handler.h b/media/audio/sounds/audio_stream_handler.h
index f814aaef5993b793052fd54bf80105f8c634d57e..ab8dcec4f652520714922947d70d71ec7f0d6444 100644
--- a/media/audio/sounds/audio_stream_handler.h
+++ b/media/audio/sounds/audio_stream_handler.h
@@ -9,9 +9,9 @@
#include "base/compiler_specific.h"
#include "base/strings/string_piece.h"
#include "base/threading/non_thread_safe.h"
+#include "base/time/time.h"
#include "media/audio/audio_io.h"
#include "media/audio/audio_parameters.h"
-#include "media/audio/sounds/wav_audio_handler.h"
#include "media/base/media_export.h"
namespace media {
@@ -53,7 +53,8 @@ class MEDIA_EXPORT AudioStreamHandler : public base::NonThreadSafe {
// Stops current playback.
void Stop();
- const WavAudioHandler& wav_audio_handler() const { return wav_audio_; }
+ // Get the duration of the WAV data passed in.
+ base::TimeDelta duration() const;
private:
friend class AudioStreamHandlerTest;
@@ -65,7 +66,7 @@ class MEDIA_EXPORT AudioStreamHandler : public base::NonThreadSafe {
static void SetAudioSourceForTesting(
AudioOutputStream::AudioSourceCallback* source);
- WavAudioHandler wav_audio_;
+ base::TimeDelta duration_;
scoped_ptr<AudioStreamContainer> stream_;
bool initialized_;

Powered by Google App Engine
This is Rietveld 408576698