| 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 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 176 return static_cast<std::string>(FLAGS_sl0); | 176 return static_cast<std::string>(FLAGS_sl0); |
| 177 } | 177 } |
| 178 | 178 |
| 179 DEFINE_string(sl1, | 179 DEFINE_string(sl1, |
| 180 "", | 180 "", |
| 181 "Comma separated values describing SpatialLayer for layer #1."); | 181 "Comma separated values describing SpatialLayer for layer #1."); |
| 182 std::string SL1() { | 182 std::string SL1() { |
| 183 return static_cast<std::string>(FLAGS_sl1); | 183 return static_cast<std::string>(FLAGS_sl1); |
| 184 } | 184 } |
| 185 | 185 |
| 186 DEFINE_string(encoded_frame_path, |
| 187 "", |
| 188 "The base path for encoded frame logs. Created files will have " |
| 189 "the form <encoded_frame_path>.<n>.(recv|send.<m>).ivf"); |
| 190 std::string EncodedFramePath() { |
| 191 return static_cast<std::string>(FLAGS_encoded_frame_path); |
| 192 } |
| 193 |
| 186 DEFINE_bool(logs, false, "print logs to stderr"); | 194 DEFINE_bool(logs, false, "print logs to stderr"); |
| 187 | 195 |
| 188 DEFINE_bool(send_side_bwe, true, "Use send-side bandwidth estimation"); | 196 DEFINE_bool(send_side_bwe, true, "Use send-side bandwidth estimation"); |
| 189 | 197 |
| 190 DEFINE_bool(allow_reordering, false, "Allow packet reordering to occur"); | 198 DEFINE_bool(allow_reordering, false, "Allow packet reordering to occur"); |
| 191 | 199 |
| 192 DEFINE_bool(use_fec, false, "Use forward error correction."); | 200 DEFINE_bool(use_fec, false, "Use forward error correction."); |
| 193 | 201 |
| 194 DEFINE_bool(audio, false, "Add audio stream"); | 202 DEFINE_bool(audio, false, "Add audio stream"); |
| 195 | 203 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 223 pipe_config.queue_delay_ms = flags::AvgPropagationDelayMs(); | 231 pipe_config.queue_delay_ms = flags::AvgPropagationDelayMs(); |
| 224 pipe_config.delay_standard_deviation_ms = flags::StdPropagationDelayMs(); | 232 pipe_config.delay_standard_deviation_ms = flags::StdPropagationDelayMs(); |
| 225 pipe_config.allow_reordering = flags::FLAGS_allow_reordering; | 233 pipe_config.allow_reordering = flags::FLAGS_allow_reordering; |
| 226 | 234 |
| 227 Call::Config::BitrateConfig call_bitrate_config; | 235 Call::Config::BitrateConfig call_bitrate_config; |
| 228 call_bitrate_config.min_bitrate_bps = flags::MinBitrateKbps() * 1000; | 236 call_bitrate_config.min_bitrate_bps = flags::MinBitrateKbps() * 1000; |
| 229 call_bitrate_config.start_bitrate_bps = flags::StartBitrateKbps() * 1000; | 237 call_bitrate_config.start_bitrate_bps = flags::StartBitrateKbps() * 1000; |
| 230 call_bitrate_config.max_bitrate_bps = flags::MaxBitrateKbps() * 1000; | 238 call_bitrate_config.max_bitrate_bps = flags::MaxBitrateKbps() * 1000; |
| 231 | 239 |
| 232 VideoQualityTest::Params params; | 240 VideoQualityTest::Params params; |
| 233 params.common = {flags::Width(), flags::Height(), flags::Fps(), | 241 params.common = {flags::Width(), |
| 234 flags::MinBitrateKbps() * 1000, flags::TargetBitrateKbps() * 1000, | 242 flags::Height(), |
| 235 flags::MaxBitrateKbps() * 1000, flags::FLAGS_suspend_below_min_bitrate, | 243 flags::Fps(), |
| 236 flags::Codec(), flags::NumTemporalLayers(), flags::SelectedTL(), | 244 flags::MinBitrateKbps() * 1000, |
| 237 0, // No min transmit bitrate. | 245 flags::TargetBitrateKbps() * 1000, |
| 238 flags::FLAGS_send_side_bwe, flags::FLAGS_use_fec, call_bitrate_config}; | 246 flags::MaxBitrateKbps() * 1000, |
| 247 flags::FLAGS_suspend_below_min_bitrate, |
| 248 flags::Codec(), |
| 249 flags::NumTemporalLayers(), |
| 250 flags::SelectedTL(), |
| 251 0, // No min transmit bitrate. |
| 252 flags::FLAGS_send_side_bwe, |
| 253 flags::FLAGS_use_fec, |
| 254 flags::EncodedFramePath(), |
| 255 call_bitrate_config}; |
| 239 params.video = {flags::Clip()}; | 256 params.video = {flags::Clip()}; |
| 240 params.analyzer = {"video", 0.0, 0.0, flags::DurationSecs(), | 257 params.analyzer = {"video", 0.0, 0.0, flags::DurationSecs(), |
| 241 flags::OutputFilename(), flags::GraphTitle()}; | 258 flags::OutputFilename(), flags::GraphTitle()}; |
| 242 params.pipe = pipe_config; | 259 params.pipe = pipe_config; |
| 243 params.logs = flags::FLAGS_logs; | 260 params.logs = flags::FLAGS_logs; |
| 244 params.audio = flags::FLAGS_audio, | 261 params.audio = flags::FLAGS_audio, |
| 245 params.audio_video_sync = flags::FLAGS_audio_video_sync; | 262 params.audio_video_sync = flags::FLAGS_audio_video_sync; |
| 246 | 263 |
| 247 std::vector<std::string> stream_descriptors; | 264 std::vector<std::string> stream_descriptors; |
| 248 stream_descriptors.push_back(flags::Stream0()); | 265 stream_descriptors.push_back(flags::Stream0()); |
| (...skipping 15 matching lines...) Expand all Loading... |
| 264 } // namespace webrtc | 281 } // namespace webrtc |
| 265 | 282 |
| 266 int main(int argc, char* argv[]) { | 283 int main(int argc, char* argv[]) { |
| 267 ::testing::InitGoogleTest(&argc, argv); | 284 ::testing::InitGoogleTest(&argc, argv); |
| 268 google::ParseCommandLineFlags(&argc, &argv, true); | 285 google::ParseCommandLineFlags(&argc, &argv, true); |
| 269 webrtc::test::InitFieldTrialsFromString( | 286 webrtc::test::InitFieldTrialsFromString( |
| 270 webrtc::flags::FLAGS_force_fieldtrials); | 287 webrtc::flags::FLAGS_force_fieldtrials); |
| 271 webrtc::test::RunTest(webrtc::Loopback); | 288 webrtc::test::RunTest(webrtc::Loopback); |
| 272 return 0; | 289 return 0; |
| 273 } | 290 } |
| OLD | NEW |