changeset 1162:081c7ebf1fea 3.0-integration

Fix omitted topmost bin
author Chris Cannam
date Fri, 04 Nov 2016 16:44:59 +0000
parents 436df5f24bda
children ab169938832a
files layer/Colour3DPlotRenderer.cpp
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/layer/Colour3DPlotRenderer.cpp	Fri Nov 04 16:32:41 2016 +0000
+++ b/layer/Colour3DPlotRenderer.cpp	Fri Nov 04 16:44:59 2016 +0000
@@ -758,6 +758,11 @@
 
     int nbins  = int(binfory[h-1]) - minbin + 1;
     if (minbin + nbins > sh) nbins = sh - minbin;
+
+#ifdef DEBUG_COLOUR_PLOT_REPAINT
+    cerr << "minbin = " << minbin << ", nbins = " << nbins << ", last binfory = "
+         << binfory[h-1] << " (model height " << sh << ")" << endl;
+#endif
     
     int psx = -1;
 
@@ -821,7 +826,7 @@
                                                     usePeaksCache);
 
                 magRange.sample(column);
-                
+
                 if (m_params.binDisplay == BinDisplay::PeakBins) {
                     column = ColumnOp::peakPick(column);
                 }