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

Unified Diff: webrtc/modules/remote_bitrate_estimator/test/metric_recorder.cc

Issue 1253473004: BWE Simulation Framework: Standard plot logging (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Comments addressed [2] Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/remote_bitrate_estimator/test/metric_recorder.cc
diff --git a/webrtc/modules/remote_bitrate_estimator/test/metric_recorder.cc b/webrtc/modules/remote_bitrate_estimator/test/metric_recorder.cc
index 90554a329433a15f92d0797a1c0a8950cdcee7a0..25e8989f5c5b8bd90012520d731195b3c4745f2a 100644
--- a/webrtc/modules/remote_bitrate_estimator/test/metric_recorder.cc
+++ b/webrtc/modules/remote_bitrate_estimator/test/metric_recorder.cc
@@ -130,7 +130,9 @@ MetricRecorder::MetricRecorder(const std::string algorithm_name,
}
void MetricRecorder::SetPlotInformation(
- const std::vector<std::string>& prefixes) {
+ const std::vector<std::string>& prefixes,
+ bool plot_delay,
+ bool plot_loss) {
assert(prefixes.size() == kNumMetrics);
for (size_t i = 0; i < kNumMetrics; ++i) {
plot_information_[i].prefix = prefixes[i];
@@ -144,10 +146,19 @@ void MetricRecorder::SetPlotInformation(
for (int i = kThroughput; i < kNumMetrics; ++i) {
plot_information_[i].last_plot_ms = 0;
- if (i == kObjective || i == kAvailablePerFlow) {
- plot_information_[i].plot = false;
- } else {
- plot_information_[i].plot = true;
+ switch (i) {
+ case kAvailablePerFlow:
+ case kObjective:
+ plot_information_[i].plot = false;
+ break;
+ case kLoss:
+ plot_information_[i].plot = plot_loss;
+ break;
+ case kDelay:
+ plot_information_[i].plot = plot_delay;
+ break;
+ default:
+ plot_information_[i].plot = true;
}
}
}

Powered by Google App Engine
This is Rietveld 408576698