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

Unified Diff: media/audio/audio_output_resampler.cc

Issue 602193003: Cleanup some audio classes with C++11 shine! (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | « no previous file | media/base/audio_converter.cc » ('j') | media/base/audio_renderer_mixer.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/audio_output_resampler.cc
diff --git a/media/audio/audio_output_resampler.cc b/media/audio/audio_output_resampler.cc
index cf966e0b6ea9c6f0cdc48663cc7e9175b58cedf8..5926996eced3c0805855f48cbb2882aa730bc24f 100644
--- a/media/audio/audio_output_resampler.cc
+++ b/media/audio/audio_output_resampler.cc
@@ -40,7 +40,7 @@ class OnMoreDataConverter
// Clears |source_callback_| and flushes the resampler.
void Stop();
- bool started() { return source_callback_ != NULL; }
+ bool started() { return source_callback_ != nullptr; }
private:
// AudioConverter::InputCallback implementation.
@@ -237,7 +237,7 @@ bool AudioOutputResampler::StartStream(
AudioOutputProxy* stream_proxy) {
DCHECK(task_runner_->BelongsToCurrentThread());
- OnMoreDataConverter* resampler_callback = NULL;
+ OnMoreDataConverter* resampler_callback = nullptr;
CallbackMap::iterator it = callbacks_.find(stream_proxy);
if (it == callbacks_.end()) {
resampler_callback = new OnMoreDataConverter(params_, output_params_);
@@ -299,7 +299,7 @@ OnMoreDataConverter::OnMoreDataConverter(const AudioParameters& input_params,
const AudioParameters& output_params)
: io_ratio_(static_cast<double>(input_params.GetBytesPerSecond()) /
output_params.GetBytesPerSecond()),
- source_callback_(NULL),
+ source_callback_(nullptr),
input_bytes_per_second_(input_params.GetBytesPerSecond()),
audio_converter_(input_params, output_params, false) {}
@@ -322,7 +322,7 @@ void OnMoreDataConverter::Start(
void OnMoreDataConverter::Stop() {
CHECK(source_callback_);
- source_callback_ = NULL;
+ source_callback_ = nullptr;
audio_converter_.RemoveInput(this);
}
« no previous file with comments | « no previous file | media/base/audio_converter.cc » ('j') | media/base/audio_renderer_mixer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698