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

Side by Side Diff: webrtc/voice_engine/test/auto_test/voe_standard_test.cc

Issue 2672583002: Remove VoEVideoSync interface. (Closed)
Patch Set: rebase Created 3 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
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 if (_file) 47 if (_file)
48 TEST_LOG(" File\n"); 48 TEST_LOG(" File\n");
49 if (_hardware) 49 if (_hardware)
50 TEST_LOG(" Hardware\n"); 50 TEST_LOG(" Hardware\n");
51 if (_netEqStats) 51 if (_netEqStats)
52 TEST_LOG(" NetEqStats\n"); 52 TEST_LOG(" NetEqStats\n");
53 if (_network) 53 if (_network)
54 TEST_LOG(" Network\n"); 54 TEST_LOG(" Network\n");
55 if (_rtp_rtcp) 55 if (_rtp_rtcp)
56 TEST_LOG(" RTP_RTCP\n"); 56 TEST_LOG(" RTP_RTCP\n");
57 if (_videoSync)
58 TEST_LOG(" VideoSync\n");
59 if (_volumeControl) 57 if (_volumeControl)
60 TEST_LOG(" VolumeControl\n"); 58 TEST_LOG(" VolumeControl\n");
61 if (_apm) 59 if (_apm)
62 TEST_LOG(" AudioProcessing\n"); 60 TEST_LOG(" AudioProcessing\n");
63 ANL(); 61 ANL();
64 TEST_LOG("Excluded sub APIs:\n\n"); 62 TEST_LOG("Excluded sub APIs:\n\n");
65 if (!_base) 63 if (!_base)
66 TEST_LOG(" Base\n"); 64 TEST_LOG(" Base\n");
67 if (!_codec) 65 if (!_codec)
68 TEST_LOG(" Codec\n"); 66 TEST_LOG(" Codec\n");
69 if (!_externalMedia) 67 if (!_externalMedia)
70 TEST_LOG(" ExternamMedia\n"); 68 TEST_LOG(" ExternamMedia\n");
71 if (!_file) 69 if (!_file)
72 TEST_LOG(" File\n"); 70 TEST_LOG(" File\n");
73 if (!_hardware) 71 if (!_hardware)
74 TEST_LOG(" Hardware\n"); 72 TEST_LOG(" Hardware\n");
75 if (!_netEqStats) 73 if (!_netEqStats)
76 TEST_LOG(" NetEqStats\n"); 74 TEST_LOG(" NetEqStats\n");
77 if (!_network) 75 if (!_network)
78 TEST_LOG(" Network\n"); 76 TEST_LOG(" Network\n");
79 if (!_rtp_rtcp) 77 if (!_rtp_rtcp)
80 TEST_LOG(" RTP_RTCP\n"); 78 TEST_LOG(" RTP_RTCP\n");
81 if (!_videoSync)
82 TEST_LOG(" VideoSync\n");
83 if (!_volumeControl) 79 if (!_volumeControl)
84 TEST_LOG(" VolumeControl\n"); 80 TEST_LOG(" VolumeControl\n");
85 if (!_apm) 81 if (!_apm)
86 TEST_LOG(" AudioProcessing\n"); 82 TEST_LOG(" AudioProcessing\n");
87 ANL(); 83 ANL();
88 } 84 }
89 85
90 VoETestManager::VoETestManager() 86 VoETestManager::VoETestManager()
91 : initialized_(false), 87 : initialized_(false),
92 voice_engine_(NULL), 88 voice_engine_(NULL),
93 voe_base_(0), 89 voe_base_(0),
94 voe_codec_(0), 90 voe_codec_(0),
95 voe_xmedia_(0), 91 voe_xmedia_(0),
96 voe_file_(0), 92 voe_file_(0),
97 voe_hardware_(0), 93 voe_hardware_(0),
98 voe_network_(0), 94 voe_network_(0),
99 voe_neteq_stats_(NULL), 95 voe_neteq_stats_(NULL),
100 voe_rtp_rtcp_(0), 96 voe_rtp_rtcp_(0),
101 voe_vsync_(0),
102 voe_volume_control_(0), 97 voe_volume_control_(0),
103 voe_apm_(0) { 98 voe_apm_(0) {
104 } 99 }
105 100
106 VoETestManager::~VoETestManager() { 101 VoETestManager::~VoETestManager() {
107 } 102 }
108 103
109 bool VoETestManager::Init() { 104 bool VoETestManager::Init() {
110 if (initialized_) 105 if (initialized_)
111 return true; 106 return true;
112 107
113 voice_engine_ = VoiceEngine::Create(); 108 voice_engine_ = VoiceEngine::Create();
114 if (!voice_engine_) { 109 if (!voice_engine_) {
115 TEST_LOG("Failed to create VoiceEngine\n"); 110 TEST_LOG("Failed to create VoiceEngine\n");
116 return false; 111 return false;
117 } 112 }
118 113
119 return true; 114 return true;
120 } 115 }
121 116
122 void VoETestManager::GetInterfaces() { 117 void VoETestManager::GetInterfaces() {
123 if (voice_engine_) { 118 if (voice_engine_) {
124 voe_base_ = VoEBase::GetInterface(voice_engine_); 119 voe_base_ = VoEBase::GetInterface(voice_engine_);
125 voe_codec_ = VoECodec::GetInterface(voice_engine_); 120 voe_codec_ = VoECodec::GetInterface(voice_engine_);
126 voe_volume_control_ = VoEVolumeControl::GetInterface(voice_engine_); 121 voe_volume_control_ = VoEVolumeControl::GetInterface(voice_engine_);
127 voe_rtp_rtcp_ = VoERTP_RTCP::GetInterface(voice_engine_); 122 voe_rtp_rtcp_ = VoERTP_RTCP::GetInterface(voice_engine_);
128 voe_apm_ = VoEAudioProcessing::GetInterface(voice_engine_); 123 voe_apm_ = VoEAudioProcessing::GetInterface(voice_engine_);
129 voe_network_ = VoENetwork::GetInterface(voice_engine_); 124 voe_network_ = VoENetwork::GetInterface(voice_engine_);
130 voe_file_ = VoEFile::GetInterface(voice_engine_); 125 voe_file_ = VoEFile::GetInterface(voice_engine_);
131 #ifdef _TEST_VIDEO_SYNC_
132 voe_vsync_ = VoEVideoSync::GetInterface(voice_engine_);
133 #endif
134 voe_hardware_ = VoEHardware::GetInterface(voice_engine_); 126 voe_hardware_ = VoEHardware::GetInterface(voice_engine_);
135 // Set the audio layer to use in all tests 127 // Set the audio layer to use in all tests
136 if (voe_hardware_) { 128 if (voe_hardware_) {
137 int res = voe_hardware_->SetAudioDeviceLayer(TESTED_AUDIO_LAYER); 129 int res = voe_hardware_->SetAudioDeviceLayer(TESTED_AUDIO_LAYER);
138 if (res < 0) { 130 if (res < 0) {
139 printf("\nERROR: failed to set audio layer to use in " 131 printf("\nERROR: failed to set audio layer to use in "
140 "testing\n"); 132 "testing\n");
141 } else { 133 } else {
142 printf("\nAudio layer %d will be used in testing\n", 134 printf("\nAudio layer %d will be used in testing\n",
143 TESTED_AUDIO_LAYER); 135 TESTED_AUDIO_LAYER);
(...skipping 30 matching lines...) Expand all
174 voe_apm_ = NULL; 166 voe_apm_ = NULL;
175 } 167 }
176 if (voe_network_) { 168 if (voe_network_) {
177 voe_network_->Release(); 169 voe_network_->Release();
178 voe_network_ = NULL; 170 voe_network_ = NULL;
179 } 171 }
180 if (voe_file_) { 172 if (voe_file_) {
181 voe_file_->Release(); 173 voe_file_->Release();
182 voe_file_ = NULL; 174 voe_file_ = NULL;
183 } 175 }
184 #ifdef _TEST_VIDEO_SYNC_
185 if (voe_vsync_) {
186 voe_vsync_->Release();
187 voe_vsync_ = NULL;
188 }
189 #endif
190 if (voe_hardware_) { 176 if (voe_hardware_) {
191 voe_hardware_->Release(); 177 voe_hardware_->Release();
192 voe_hardware_ = NULL; 178 voe_hardware_ = NULL;
193 } 179 }
194 #ifdef _TEST_XMEDIA_ 180 #ifdef _TEST_XMEDIA_
195 if (voe_xmedia_) { 181 if (voe_xmedia_) {
196 voe_xmedia_->Release(); 182 voe_xmedia_->Release();
197 voe_xmedia_ = NULL; 183 voe_xmedia_ = NULL;
198 } 184 }
199 #endif 185 #endif
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
317 google::AllowCommandLineReparsing(); 303 google::AllowCommandLineReparsing();
318 google::ParseCommandLineFlags(&argc, &argv, true); 304 google::ParseCommandLineFlags(&argc, &argv, true);
319 305
320 if (FLAGS_automated) { 306 if (FLAGS_automated) {
321 return RunInAutomatedMode(); 307 return RunInAutomatedMode();
322 } 308 }
323 309
324 return RunInManualMode(); 310 return RunInManualMode();
325 } 311 }
326 #endif //#if !defined(WEBRTC_IOS) 312 #endif //#if !defined(WEBRTC_IOS)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698