Mercurial > hg > svgui
comparison layer/Colour3DPlotRenderer.cpp @ 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 |
comparison
equal
deleted
inserted
replaced
1161:436df5f24bda | 1162:081c7ebf1fea |
---|---|
756 if (minbin >= sh) minbin = sh - 1; | 756 if (minbin >= sh) minbin = sh - 1; |
757 if (minbin < 0) minbin = 0; | 757 if (minbin < 0) minbin = 0; |
758 | 758 |
759 int nbins = int(binfory[h-1]) - minbin + 1; | 759 int nbins = int(binfory[h-1]) - minbin + 1; |
760 if (minbin + nbins > sh) nbins = sh - minbin; | 760 if (minbin + nbins > sh) nbins = sh - minbin; |
761 | |
762 #ifdef DEBUG_COLOUR_PLOT_REPAINT | |
763 cerr << "minbin = " << minbin << ", nbins = " << nbins << ", last binfory = " | |
764 << binfory[h-1] << " (model height " << sh << ")" << endl; | |
765 #endif | |
761 | 766 |
762 int psx = -1; | 767 int psx = -1; |
763 | 768 |
764 int start = 0; | 769 int start = 0; |
765 int finish = w; | 770 int finish = w; |
819 // this does the first three: | 824 // this does the first three: |
820 ColumnOp::Column column = getColumn(sx, minbin, nbins, | 825 ColumnOp::Column column = getColumn(sx, minbin, nbins, |
821 usePeaksCache); | 826 usePeaksCache); |
822 | 827 |
823 magRange.sample(column); | 828 magRange.sample(column); |
824 | 829 |
825 if (m_params.binDisplay == BinDisplay::PeakBins) { | 830 if (m_params.binDisplay == BinDisplay::PeakBins) { |
826 column = ColumnOp::peakPick(column); | 831 column = ColumnOp::peakPick(column); |
827 } | 832 } |
828 | 833 |
829 preparedColumn = | 834 preparedColumn = |