Mercurial > hg > svgui
comparison layer/Colour3DPlotRenderer.cpp @ 1141:f19dcb288123 spectrogram-minor-refactor
Minor tidy, + go back to opaque-only spectrogram as intended
author | Chris Cannam |
---|---|
date | Fri, 05 Aug 2016 13:48:14 +0100 |
parents | 2976f57164ac |
children | c53ed1a6fcbd |
comparison
equal
deleted
inserted
replaced
1140:ca910d8070c8 | 1141:f19dcb288123 |
---|---|
236 QRect pr = rect & m_cache.getValidArea(); | 236 QRect pr = rect & m_cache.getValidArea(); |
237 paint.drawImage(pr.x(), pr.y(), m_cache.getImage(), | 237 paint.drawImage(pr.x(), pr.y(), m_cache.getImage(), |
238 pr.x(), pr.y(), pr.width(), pr.height()); | 238 pr.x(), pr.y(), pr.width(), pr.height()); |
239 | 239 |
240 if (!timeConstrained && (pr != rect)) { | 240 if (!timeConstrained && (pr != rect)) { |
241 //!!! on a first cut, there is a risk that this will happen | 241 cerr << "WARNING: failed to render entire requested rect " |
242 //!!! when we are at start/end of model -- trap, report, and | 242 << "even when not time-constrained" << endl; |
243 //!!! then fix | |
244 throw std::logic_error("internal error: failed to render entire requested rect even when not time-constrained"); | |
245 } | 243 } |
246 | 244 |
247 MagnitudeRange range = m_magCache.getRange(reqx0, reqx1 - reqx0); | 245 MagnitudeRange range = m_magCache.getRange(reqx0, reqx1 - reqx0); |
248 | 246 |
249 return { pr, range }; | 247 return { pr, range }; |
250 | |
251 //!!! todo, here or in caller: illuminateLocalFeatures | |
252 | |
253 //!!! todo: handle vertical range other than full range of column | |
254 | |
255 //!!! fft model scaling? | |
256 } | 248 } |
257 | 249 |
258 Colour3DPlotRenderer::RenderType | 250 Colour3DPlotRenderer::RenderType |
259 Colour3DPlotRenderer::decideRenderType(const LayerGeometryProvider *v) const | 251 Colour3DPlotRenderer::decideRenderType(const LayerGeometryProvider *v) const |
260 { | 252 { |