OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2016 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 <iostream> | 11 #include <iostream> |
12 | 12 |
13 #include "webrtc/base/flags.h" | 13 #include "webrtc/base/flags.h" |
14 #include "webrtc/logging/rtc_event_log/rtc_event_log_parser.h" | 14 #include "webrtc/logging/rtc_event_log/rtc_event_log_parser.h" |
15 #include "webrtc/test/field_trial.h" | 15 #include "webrtc/test/field_trial.h" |
| 16 #include "webrtc/test/testsupport/fileutils.h" |
16 #include "webrtc/tools/event_log_visualizer/analyzer.h" | 17 #include "webrtc/tools/event_log_visualizer/analyzer.h" |
17 #include "webrtc/tools/event_log_visualizer/plot_base.h" | 18 #include "webrtc/tools/event_log_visualizer/plot_base.h" |
18 #include "webrtc/tools/event_log_visualizer/plot_python.h" | 19 #include "webrtc/tools/event_log_visualizer/plot_python.h" |
19 | 20 |
20 DEFINE_bool(incoming, true, "Plot statistics for incoming packets."); | 21 DEFINE_bool(incoming, true, "Plot statistics for incoming packets."); |
21 DEFINE_bool(outgoing, true, "Plot statistics for outgoing packets."); | 22 DEFINE_bool(outgoing, true, "Plot statistics for outgoing packets."); |
22 DEFINE_bool(plot_all, true, "Plot all different data types."); | 23 DEFINE_bool(plot_all, true, "Plot all different data types."); |
23 DEFINE_bool(plot_packets, | 24 DEFINE_bool(plot_packets, |
24 false, | 25 false, |
25 "Plot bar graph showing the size of each packet."); | 26 "Plot bar graph showing the size of each packet."); |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 "Plot the audio encoder frame length."); | 71 "Plot the audio encoder frame length."); |
71 DEFINE_bool( | 72 DEFINE_bool( |
72 audio_encoder_uplink_packet_loss_fraction, | 73 audio_encoder_uplink_packet_loss_fraction, |
73 false, | 74 false, |
74 "Plot the uplink packet loss fraction which is send to the audio encoder."); | 75 "Plot the uplink packet loss fraction which is send to the audio encoder."); |
75 DEFINE_bool(audio_encoder_fec, false, "Plot the audio encoder FEC."); | 76 DEFINE_bool(audio_encoder_fec, false, "Plot the audio encoder FEC."); |
76 DEFINE_bool(audio_encoder_dtx, false, "Plot the audio encoder DTX."); | 77 DEFINE_bool(audio_encoder_dtx, false, "Plot the audio encoder DTX."); |
77 DEFINE_bool(audio_encoder_num_channels, | 78 DEFINE_bool(audio_encoder_num_channels, |
78 false, | 79 false, |
79 "Plot the audio encoder number of channels."); | 80 "Plot the audio encoder number of channels."); |
| 81 DEFINE_bool(plot_audio_jitter_buffer, |
| 82 false, |
| 83 "Plot the audio jitter buffer delay profile."); |
80 DEFINE_string( | 84 DEFINE_string( |
81 force_fieldtrials, | 85 force_fieldtrials, |
82 "", | 86 "", |
83 "Field trials control experimental feature code which can be forced. " | 87 "Field trials control experimental feature code which can be forced. " |
84 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enabled/" | 88 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enabled/" |
85 " will assign the group Enabled to field trial WebRTC-FooFeature. Multiple " | 89 " will assign the group Enabled to field trial WebRTC-FooFeature. Multiple " |
86 "trials are separated by \"/\""); | 90 "trials are separated by \"/\""); |
87 DEFINE_bool(help, false, "prints this message"); | 91 DEFINE_bool(help, false, "prints this message"); |
88 | 92 |
89 int main(int argc, char* argv[]) { | 93 int main(int argc, char* argv[]) { |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 } | 228 } |
225 | 229 |
226 if (FLAG_plot_all || FLAG_audio_encoder_dtx) { | 230 if (FLAG_plot_all || FLAG_audio_encoder_dtx) { |
227 analyzer.CreateAudioEncoderEnableDtxGraph(collection->AppendNewPlot()); | 231 analyzer.CreateAudioEncoderEnableDtxGraph(collection->AppendNewPlot()); |
228 } | 232 } |
229 | 233 |
230 if (FLAG_plot_all || FLAG_audio_encoder_num_channels) { | 234 if (FLAG_plot_all || FLAG_audio_encoder_num_channels) { |
231 analyzer.CreateAudioEncoderNumChannelsGraph(collection->AppendNewPlot()); | 235 analyzer.CreateAudioEncoderNumChannelsGraph(collection->AppendNewPlot()); |
232 } | 236 } |
233 | 237 |
| 238 if (FLAG_plot_all || FLAG_plot_audio_jitter_buffer) { |
| 239 analyzer.CreateAudioJitterBufferGraph( |
| 240 webrtc::test::ResourcePath( |
| 241 "audio_processing/conversational_speech/EN_script2_F_sp2_B1", |
| 242 "wav"), |
| 243 48000, collection->AppendNewPlot()); |
| 244 } |
| 245 |
234 collection->Draw(); | 246 collection->Draw(); |
235 | 247 |
236 return 0; | 248 return 0; |
237 } | 249 } |
OLD | NEW |