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

Side by Side Diff: webrtc/voice_engine/test/cmd_test/voe_cmd_test.cc

Issue 1702983002: Replace scoped_ptr with unique_ptr in webrtc/voice_engine/ (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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
11 #include <stdio.h> 11 #include <stdio.h>
12 #include <stdlib.h> 12 #include <stdlib.h>
13 #include <string.h> 13 #include <string.h>
14 #ifndef _WIN32 14 #ifndef _WIN32
15 #include <unistd.h> 15 #include <unistd.h>
16 #endif 16 #endif
17 17
18 #include <memory>
18 #include <vector> 19 #include <vector>
19 20
20 #include "gflags/gflags.h" 21 #include "gflags/gflags.h"
21 #include "testing/gtest/include/gtest/gtest.h" 22 #include "testing/gtest/include/gtest/gtest.h"
22 #include "webrtc/base/format_macros.h" 23 #include "webrtc/base/format_macros.h"
23 #include "webrtc/base/scoped_ptr.h"
24 #include "webrtc/call/rtc_event_log.h" 24 #include "webrtc/call/rtc_event_log.h"
25 #include "webrtc/engine_configurations.h" 25 #include "webrtc/engine_configurations.h"
26 #include "webrtc/modules/audio_processing/include/audio_processing.h" 26 #include "webrtc/modules/audio_processing/include/audio_processing.h"
27 #include "webrtc/test/channel_transport/channel_transport.h" 27 #include "webrtc/test/channel_transport/channel_transport.h"
28 #include "webrtc/test/testsupport/fileutils.h" 28 #include "webrtc/test/testsupport/fileutils.h"
29 #include "webrtc/test/testsupport/trace_to_stderr.h" 29 #include "webrtc/test/testsupport/trace_to_stderr.h"
30 #include "webrtc/voice_engine/include/voe_audio_processing.h" 30 #include "webrtc/voice_engine/include/voe_audio_processing.h"
31 #include "webrtc/voice_engine/include/voe_base.h" 31 #include "webrtc/voice_engine/include/voe_base.h"
32 #include "webrtc/voice_engine/include/voe_codec.h" 32 #include "webrtc/voice_engine/include/voe_codec.h"
33 #include "webrtc/voice_engine/include/voe_dtmf.h" 33 #include "webrtc/voice_engine/include/voe_dtmf.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 rtp_rtcp = VoERTP_RTCP::GetInterface(m_voe); 135 rtp_rtcp = VoERTP_RTCP::GetInterface(m_voe);
136 netw = VoENetwork::GetInterface(m_voe); 136 netw = VoENetwork::GetInterface(m_voe);
137 file = VoEFile::GetInterface(m_voe); 137 file = VoEFile::GetInterface(m_voe);
138 vsync = VoEVideoSync::GetInterface(m_voe); 138 vsync = VoEVideoSync::GetInterface(m_voe);
139 hardware = VoEHardware::GetInterface(m_voe); 139 hardware = VoEHardware::GetInterface(m_voe);
140 xmedia = VoEExternalMedia::GetInterface(m_voe); 140 xmedia = VoEExternalMedia::GetInterface(m_voe);
141 neteqst = VoENetEqStats::GetInterface(m_voe); 141 neteqst = VoENetEqStats::GetInterface(m_voe);
142 142
143 MyObserver my_observer; 143 MyObserver my_observer;
144 144
145 rtc::scoped_ptr<test::TraceToStderr> trace_to_stderr; 145 std::unique_ptr<test::TraceToStderr> trace_to_stderr;
146 if (!FLAGS_use_log_file) { 146 if (!FLAGS_use_log_file) {
147 trace_to_stderr.reset(new test::TraceToStderr); 147 trace_to_stderr.reset(new test::TraceToStderr);
148 } else { 148 } else {
149 const std::string trace_filename = test::OutputPath() + "webrtc_trace.txt"; 149 const std::string trace_filename = test::OutputPath() + "webrtc_trace.txt";
150 VoiceEngine::SetTraceFilter(kTraceAll); 150 VoiceEngine::SetTraceFilter(kTraceAll);
151 res = VoiceEngine::SetTraceFile(trace_filename.c_str()); 151 res = VoiceEngine::SetTraceFile(trace_filename.c_str());
152 VALIDATE; 152 VALIDATE;
153 res = VoiceEngine::SetTraceCallback(NULL); 153 res = VoiceEngine::SetTraceCallback(NULL);
154 VALIDATE; 154 VALIDATE;
155 printf("Outputting logs to file: %s\n", trace_filename.c_str()); 155 printf("Outputting logs to file: %s\n", trace_filename.c_str());
(...skipping 705 matching lines...) Expand 10 before | Expand all | Expand 10 after
861 861
862 printf("Delete channels \n"); 862 printf("Delete channels \n");
863 res = base1->DeleteChannel(chan); 863 res = base1->DeleteChannel(chan);
864 VALIDATE; 864 VALIDATE;
865 865
866 for (int i = 0; i < kMaxNumChannels; ++i) { 866 for (int i = 0; i < kMaxNumChannels; ++i) {
867 res = base1->DeleteChannel(channels[i]); 867 res = base1->DeleteChannel(channels[i]);
868 VALIDATE; 868 VALIDATE;
869 } 869 }
870 } 870 }
OLDNEW
« no previous file with comments | « webrtc/voice_engine/test/auto_test/voe_stress_test.cc ('k') | webrtc/voice_engine/transmit_mixer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698