Visualize simulated BWE as a piecewise constant function.

To facilitate this change, I replaced the graph style with one style
config for lines/interpolation and one style config for points.
The output functions were updated to make use of the new styles.

Bug: None
Change-Id: I42404a8ce274d6e433bcdd6aee4b15b640e78b40
Reviewed-on: https://webrtc-review.googlesource.com/22000
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20645}
This commit is contained in:
Bjorn Terelius
2017-11-10 16:21:34 +01:00
committed by Commit Bot
parent 13f35ec3d7
commit b577d5e4c3
4 changed files with 118 additions and 79 deletions

View File

@ -31,22 +31,21 @@ void ProtobufPlot::ExportProtobuf(webrtc::analytics::Chart* chart) {
data_set->add_y_values(point.y);
}
if (series_list_[i].style == BAR_GRAPH) {
if (series_list_[i].line_style == LineStyle::kBar) {
data_set->set_style(webrtc::analytics::ChartStyle::BAR_CHART);
} else if (series_list_[i].style == LINE_GRAPH) {
} else if (series_list_[i].line_style == LineStyle::kLine) {
data_set->set_style(webrtc::analytics::ChartStyle::LINE_CHART);
} else if (series_list_[i].style == LINE_DOT_GRAPH) {
data_set->set_style(webrtc::analytics::ChartStyle::LINE_CHART);
data_set->set_highlight_points(true);
} else if (series_list_[i].style == LINE_STEP_GRAPH) {
} else if (series_list_[i].line_style == LineStyle::kStep) {
data_set->set_style(webrtc::analytics::ChartStyle::LINE_STEP_CHART);
} else if (series_list_[i].style == DOT_GRAPH) {
} else if (series_list_[i].line_style == LineStyle::kNone) {
data_set->set_style(webrtc::analytics::ChartStyle::SCATTER_CHART);
data_set->set_highlight_points(true);
} else {
data_set->set_style(webrtc::analytics::ChartStyle::UNDEFINED);
}
if (series_list_[i].point_style == PointStyle::kHighlight)
data_set->set_highlight_points(true);
data_set->set_label(series_list_[i].label);
}