From 5b0f9491c5549121d641dad1b96bc118cc9b0509 2017-09-08 07:27:47 From: leroux Date: 2017-09-08 07:27:47 Subject: [PATCH] Merge pull request #265 from SCIQLOP develop Perf improvement on vector points interleaving --- diff --git a/core/meson.build b/core/meson.build index f3acbb0..195cd0b 100644 --- a/core/meson.build +++ b/core/meson.build @@ -1,7 +1,6 @@ core_moc_headers = [ 'include/Data/IDataProvider.h', - 'include/Data/DataSeriesMergeHelper.h', 'include/DataSource/DataSourceController.h', 'include/DataSource/DataSourceItemAction.h', 'include/Network/NetworkController.h', diff --git a/core/src/Data/VectorSeries.cpp b/core/src/Data/VectorSeries.cpp index 879d689..a51b0cc 100644 --- a/core/src/Data/VectorSeries.cpp +++ b/core/src/Data/VectorSeries.cpp @@ -29,13 +29,11 @@ std::vector flatten(std::vector xValues, std::vector yVa auto result = std::vector(); result.reserve(xValues.size() * 3); - - while (!xValues.empty()) { - result.insert(result.cend(), {xValues.front(), yValues.front(), zValues.front()}); - xValues.erase(xValues.begin()); - yValues.erase(yValues.begin()); - zValues.erase(zValues.begin()); - } + for (int i = 0; i < xValues.size(); i++) { + result.push_back(xValues[i]); + result.push_back(yValues[i]); + result.push_back(zValues[i]); + } return result; } diff --git a/gui/meson.build b/gui/meson.build index 8fe81c1..1011d4f 100644 --- a/gui/meson.build +++ b/gui/meson.build @@ -48,7 +48,7 @@ gui_sources = [ 'src/TimeWidget/TimeWidget.cpp', 'src/Variable/VariableInspectorWidget.cpp', 'src/Variable/VariableMenuHeaderWidget.cpp', - 'src/Variable/RenamevariableDialog.cpp', + 'src/Variable/RenameVariableDialog.cpp', 'src/Visualization/VisualizationGraphHelper.cpp', 'src/Visualization/VisualizationGraphRenderingDelegate.cpp', 'src/Visualization/VisualizationGraphWidget.cpp',