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

Unified Diff: media/audio/pulse/pulse_input.h

Issue 396263004: Switch the input code to use AudioBlockFifo (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: addressed the comments. Created 6 years, 5 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/mac/audio_low_latency_input_mac.cc ('k') | media/audio/pulse/pulse_input.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/pulse/pulse_input.h
diff --git a/media/audio/pulse/pulse_input.h b/media/audio/pulse/pulse_input.h
index 7e64bb296a8749c0a15ce2fa3679897a29f338bb..9f08379cef9ca005dab5e45318f86ba78add8268 100644
--- a/media/audio/pulse/pulse_input.h
+++ b/media/audio/pulse/pulse_input.h
@@ -12,6 +12,7 @@
#include "media/audio/audio_device_name.h"
#include "media/audio/audio_io.h"
#include "media/audio/audio_parameters.h"
+#include "media/base/audio_block_fifo.h"
struct pa_context;
struct pa_source_info;
@@ -21,7 +22,6 @@ struct pa_threaded_mainloop;
namespace media {
class AudioManagerPulse;
-class SeekableBuffer;
class PulseAudioInputStream : public AgcAudioStream<AudioInputStream> {
public:
@@ -61,11 +61,7 @@ class PulseAudioInputStream : public AgcAudioStream<AudioInputStream> {
bool stream_started_;
// Holds the data from the OS.
- scoped_ptr<media::SeekableBuffer> buffer_;
-
- // Temporary storage for recorded data. It gets a packet of data from
- // |buffer_| and deliver the data to OnData() callback.
- scoped_ptr<uint8[]> audio_data_buffer_;
+ AudioBlockFifo fifo_;
// PulseAudio API structs.
pa_threaded_mainloop* pa_mainloop_; // Weak.
@@ -75,8 +71,6 @@ class PulseAudioInputStream : public AgcAudioStream<AudioInputStream> {
// Flag indicating the state of the context has been changed.
bool context_state_changed_;
- scoped_ptr<AudioBus> audio_bus_;
-
base::ThreadChecker thread_checker_;
DISALLOW_COPY_AND_ASSIGN(PulseAudioInputStream);
« no previous file with comments | « media/audio/mac/audio_low_latency_input_mac.cc ('k') | media/audio/pulse/pulse_input.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698