OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
184 } | 184 } |
185 | 185 |
186 DEFINE_bool(logs, false, "print logs to stderr"); | 186 DEFINE_bool(logs, false, "print logs to stderr"); |
187 | 187 |
188 DEFINE_bool(send_side_bwe, true, "Use send-side bandwidth estimation"); | 188 DEFINE_bool(send_side_bwe, true, "Use send-side bandwidth estimation"); |
189 | 189 |
190 DEFINE_bool(allow_reordering, false, "Allow packet reordering to occur"); | 190 DEFINE_bool(allow_reordering, false, "Allow packet reordering to occur"); |
191 | 191 |
192 DEFINE_bool(use_fec, false, "Use forward error correction."); | 192 DEFINE_bool(use_fec, false, "Use forward error correction."); |
193 | 193 |
194 DEFINE_bool(audio, false, "Add audio stream"); | |
195 | |
196 DEFINE_bool(audio_video_sync, false, "Sync audio and video stream (no effect if" | |
197 " audio is false)"); | |
198 | |
199 DEFINE_string( | 194 DEFINE_string( |
200 force_fieldtrials, | 195 force_fieldtrials, |
201 "", | 196 "", |
202 "Field trials control experimental feature code which can be forced. " | 197 "Field trials control experimental feature code which can be forced. " |
203 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enable/" | 198 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enable/" |
204 " will assign the group Enable to field trial WebRTC-FooFeature. Multiple " | 199 " will assign the group Enable to field trial WebRTC-FooFeature. Multiple " |
205 "trials are separated by \"/\""); | 200 "trials are separated by \"/\""); |
206 | 201 |
207 // Video-specific flags. | 202 // Video-specific flags. |
208 DEFINE_string(clip, | 203 DEFINE_string(clip, |
(...skipping 25 matching lines...) Expand all Loading... |
234 flags::MinBitrateKbps() * 1000, flags::TargetBitrateKbps() * 1000, | 229 flags::MinBitrateKbps() * 1000, flags::TargetBitrateKbps() * 1000, |
235 flags::MaxBitrateKbps() * 1000, flags::FLAGS_suspend_below_min_bitrate, | 230 flags::MaxBitrateKbps() * 1000, flags::FLAGS_suspend_below_min_bitrate, |
236 flags::Codec(), flags::NumTemporalLayers(), flags::SelectedTL(), | 231 flags::Codec(), flags::NumTemporalLayers(), flags::SelectedTL(), |
237 0, // No min transmit bitrate. | 232 0, // No min transmit bitrate. |
238 flags::FLAGS_send_side_bwe, flags::FLAGS_use_fec, call_bitrate_config}, | 233 flags::FLAGS_send_side_bwe, flags::FLAGS_use_fec, call_bitrate_config}, |
239 {flags::Clip()}, | 234 {flags::Clip()}, |
240 {}, // Screenshare specific. | 235 {}, // Screenshare specific. |
241 {"video", 0.0, 0.0, flags::DurationSecs(), flags::OutputFilename(), | 236 {"video", 0.0, 0.0, flags::DurationSecs(), flags::OutputFilename(), |
242 flags::GraphTitle()}, | 237 flags::GraphTitle()}, |
243 pipe_config, | 238 pipe_config, |
244 flags::FLAGS_logs, | 239 flags::FLAGS_logs}; |
245 {}, // ss. | |
246 flags::FLAGS_audio, | |
247 flags::FLAGS_audio_video_sync}; | |
248 | 240 |
249 std::vector<std::string> stream_descriptors; | 241 std::vector<std::string> stream_descriptors; |
250 stream_descriptors.push_back(flags::Stream0()); | 242 stream_descriptors.push_back(flags::Stream0()); |
251 stream_descriptors.push_back(flags::Stream1()); | 243 stream_descriptors.push_back(flags::Stream1()); |
252 std::vector<std::string> SL_descriptors; | 244 std::vector<std::string> SL_descriptors; |
253 SL_descriptors.push_back(flags::SL0()); | 245 SL_descriptors.push_back(flags::SL0()); |
254 SL_descriptors.push_back(flags::SL1()); | 246 SL_descriptors.push_back(flags::SL1()); |
255 VideoQualityTest::FillScalabilitySettings( | 247 VideoQualityTest::FillScalabilitySettings( |
256 ¶ms, stream_descriptors, flags::SelectedStream(), | 248 ¶ms, stream_descriptors, flags::SelectedStream(), |
257 flags::NumSpatialLayers(), flags::SelectedSL(), SL_descriptors); | 249 flags::NumSpatialLayers(), flags::SelectedSL(), SL_descriptors); |
258 | 250 |
259 VideoQualityTest test; | 251 VideoQualityTest test; |
260 if (flags::DurationSecs()) { | 252 if (flags::DurationSecs()) { |
261 test.RunWithAnalyzer(params); | 253 test.RunWithAnalyzer(params); |
262 } else { | 254 } else { |
263 test.RunWithRenderers(params); | 255 test.RunWithVideoRenderer(params); |
264 } | 256 } |
265 } | 257 } |
266 } // namespace webrtc | 258 } // namespace webrtc |
267 | 259 |
268 int main(int argc, char* argv[]) { | 260 int main(int argc, char* argv[]) { |
269 ::testing::InitGoogleTest(&argc, argv); | 261 ::testing::InitGoogleTest(&argc, argv); |
270 google::ParseCommandLineFlags(&argc, &argv, true); | 262 google::ParseCommandLineFlags(&argc, &argv, true); |
271 webrtc::test::InitFieldTrialsFromString( | 263 webrtc::test::InitFieldTrialsFromString( |
272 webrtc::flags::FLAGS_force_fieldtrials); | 264 webrtc::flags::FLAGS_force_fieldtrials); |
273 webrtc::test::RunTest(webrtc::Loopback); | 265 webrtc::test::RunTest(webrtc::Loopback); |
274 return 0; | 266 return 0; |
275 } | 267 } |
OLD | NEW |