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

Unified Diff: webrtc/modules/audio_processing/test/debug_dump_test.cc

Issue 1694423002: Replace scoped_ptr with unique_ptr in webrtc/modules/audio_processing/test/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 10 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: webrtc/modules/audio_processing/test/debug_dump_test.cc
diff --git a/webrtc/modules/audio_processing/test/debug_dump_test.cc b/webrtc/modules/audio_processing/test/debug_dump_test.cc
index e3b375e525c42e5db9f0712a15fbc6d68811a511..6ca82a4d4376f6578d2c115a95592f14ba2f6135 100644
--- a/webrtc/modules/audio_processing/test/debug_dump_test.cc
+++ b/webrtc/modules/audio_processing/test/debug_dump_test.cc
@@ -9,12 +9,13 @@
*/
#include <stddef.h> // size_t
+
+#include <memory>
#include <string>
#include <vector>
#include "testing/gtest/include/gtest/gtest.h"
#include "webrtc/base/checks.h"
-#include "webrtc/base/scoped_ptr.h"
#include "webrtc/common_audio/channel_buffer.h"
#include "webrtc/modules/audio_coding/neteq/tools/resample_input_audio_file.h"
#include "webrtc/modules/audio_processing/debug.pb.h"
@@ -28,7 +29,7 @@ namespace test {
namespace {
-void MaybeResetBuffer(rtc::scoped_ptr<ChannelBuffer<float>>* buffer,
+void MaybeResetBuffer(std::unique_ptr<ChannelBuffer<float>>* buffer,
const StreamConfig& config) {
auto& buffer_ref = *buffer;
if (!buffer_ref.get() || buffer_ref->num_frames() != config.num_frames() ||
@@ -101,11 +102,11 @@ class DebugDumpGenerator {
const int reverse_file_channels_;
// Buffer for APM input/output.
- rtc::scoped_ptr<ChannelBuffer<float>> input_;
- rtc::scoped_ptr<ChannelBuffer<float>> reverse_;
- rtc::scoped_ptr<ChannelBuffer<float>> output_;
+ std::unique_ptr<ChannelBuffer<float>> input_;
+ std::unique_ptr<ChannelBuffer<float>> reverse_;
+ std::unique_ptr<ChannelBuffer<float>> output_;
- rtc::scoped_ptr<AudioProcessing> apm_;
+ std::unique_ptr<AudioProcessing> apm_;
const std::string dump_file_name_;
};
@@ -250,11 +251,11 @@ class DebugDumpTest : public ::testing::Test {
void ConfigureApm(const audioproc::Config& msg);
// Buffer for APM input/output.
- rtc::scoped_ptr<ChannelBuffer<float>> input_;
- rtc::scoped_ptr<ChannelBuffer<float>> reverse_;
- rtc::scoped_ptr<ChannelBuffer<float>> output_;
+ std::unique_ptr<ChannelBuffer<float>> input_;
+ std::unique_ptr<ChannelBuffer<float>> reverse_;
+ std::unique_ptr<ChannelBuffer<float>> output_;
- rtc::scoped_ptr<AudioProcessing> apm_;
+ std::unique_ptr<AudioProcessing> apm_;
StreamConfig input_config_;
StreamConfig reverse_config_;
« no previous file with comments | « webrtc/modules/audio_processing/test/audioproc_float.cc ('k') | webrtc/modules/audio_processing/test/process_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698