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

Unified Diff: media/audio/pulse/audio_manager_pulse.cc

Issue 314713002: Modifies AudioInputCallback::OnData and use media::AudioBus instead of plain byte vector (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed fake input stream as well Created 6 years, 6 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
Index: media/audio/pulse/audio_manager_pulse.cc
diff --git a/media/audio/pulse/audio_manager_pulse.cc b/media/audio/pulse/audio_manager_pulse.cc
index 412f2a421b0f46dd6375bf7ab3d7d17d051484fe..c6983279d9330d20814fc426c735aff2e8fe1304 100644
--- a/media/audio/pulse/audio_manager_pulse.cc
+++ b/media/audio/pulse/audio_manager_pulse.cc
@@ -40,7 +40,7 @@ static const int kMinimumOutputBufferSize = 512;
static const int kMaximumOutputBufferSize = 8192;
// Default input buffer size.
-static const int kDefaultInputBufferSize = 1024;
+static const int kDefaultInputBufferSize = 512;
static const base::FilePath::CharType kPulseLib[] =
FILE_PATH_LITERAL("libpulse.so.0");
@@ -61,10 +61,12 @@ AudioManagerPulse::AudioManagerPulse(AudioLogFactory* audio_log_factory)
input_context_(NULL),
devices_(NULL),
native_input_sample_rate_(0) {
+ DVLOG(1) << __FUNCTION__;
SetMaxOutputStreamsAllowed(kMaxOutputStreams);
}
AudioManagerPulse::~AudioManagerPulse() {
+ DVLOG(1) << __FUNCTION__;
Shutdown();
// The Pulse objects are the last things to be destroyed since Shutdown()
@@ -128,6 +130,7 @@ void AudioManagerPulse::GetAudioOutputDeviceNames(
AudioParameters AudioManagerPulse::GetInputStreamParameters(
const std::string& device_id) {
+ DVLOG(1) << "AudioManagerPulse::GetInputStreamParameters";
int user_buffer_size = GetUserBufferSize();
int buffer_size = user_buffer_size ?
user_buffer_size : kDefaultInputBufferSize;
@@ -168,6 +171,7 @@ AudioInputStream* AudioManagerPulse::MakeLowLatencyInputStream(
AudioParameters AudioManagerPulse::GetPreferredOutputStreamParameters(
const std::string& output_device_id,
const AudioParameters& input_params) {
+ DVLOG(1) << "AudioManagerPulse::GetPreferredOutputStreamParameters";
// TODO(tommi): Support |output_device_id|.
VLOG_IF(0, !output_device_id.empty()) << "Not implemented!";

Powered by Google App Engine
This is Rietveld 408576698