diff options
author | Samuel Fadel <samuelfadel@gmail.com> | 2016-04-07 17:33:35 -0300 |
---|---|---|
committer | Samuel Fadel <samuelfadel@gmail.com> | 2016-04-07 17:33:35 -0300 |
commit | 7d2b578c068d4e78250884c576c892b0a609d789 (patch) | |
tree | aa785fc6c39c2556c438c0b31e117246fcc808cc /lineplot.cpp | |
parent | cf0a22d22a402f230d834853416a074833fe08bf (diff) |
LinePlot: less pointers to GDrawings.
Diffstat (limited to 'lineplot.cpp')
-rw-r--r-- | lineplot.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lineplot.cpp b/lineplot.cpp index 0e9e001..35654be 100644 --- a/lineplot.cpp +++ b/lineplot.cpp @@ -60,20 +60,18 @@ void LinePlot::setColorScale(const ColorScale *scale) void LinePlot::relax() { - m_gdFinalPtr.reset(new GraphDrawing); - *m_gdFinalPtr.get() = *m_gdBundlePtr.get(); - m_gdFinalPtr.get()->interpolate(*m_gdPtr.get(), m_relaxation); + m_gdFinal = m_gdBundle; + m_gdFinal.interpolate(*m_gdPtr.get(), m_relaxation); setLinesChanged(true); } void LinePlot::bundle() { - m_gdBundlePtr.reset(new GraphDrawing); - *m_gdBundlePtr.get() = *m_gdPtr.get(); + m_gdBundle = *m_gdPtr.get(); CPUBundling bundling(std::min(width(), height())); - bundling.setInput(m_gdBundlePtr.get()); + bundling.setInput(&m_gdBundle); bundling.niter = m_iterations; bundling.h = m_kernelSize; |