diff layer/Colour3DPlotRenderer.cpp @ 1075:2e1d6c2ed3ee spectrogram-minor-refactor

Another tiny bit
author Chris Cannam
date Wed, 29 Jun 2016 15:13:54 +0100
parents 6f98aa5291d4
children e536dfc6b250
line wrap: on
line diff
--- a/layer/Colour3DPlotRenderer.cpp	Wed Jun 29 14:04:57 2016 +0100
+++ b/layer/Colour3DPlotRenderer.cpp	Wed Jun 29 15:13:54 2016 +0100
@@ -16,11 +16,30 @@
 #include "Colour3DPlotRenderer.h"
 #include "RenderTimer.h"
 
+#include "data/model/DenseThreeDimensionalModel.h"
+#include "data/model/Dense3DModelPeakCache.h"
+#include "data/model/FFTModel.h"
+
+#include "view/LayerGeometryProvider.h"
+
 Colour3DPlotRenderer::RenderResult
 Colour3DPlotRenderer::render(QPainter &paint,
 			     QRect rect,
 			     bool complete)
 {
+    LayerGeometryProvider *v = m_sources.geometryProvider;
+    if (!v) {
+	throw std::logic_error("no LayerGeometryProvider provided");
+    }
+
+    DenseThreeDimensionalModel *model = m_sources.source;
+    if (!model || !model->isOK() || !model->isReady()) {
+	throw std::logic_error("no source model provided, or model not ready");
+    }
+	
+    sv_frame_t startFrame = v->getStartFrame();
+
+    
     //!!! todo: timing/incomplete paint
 
     //!!! todo: peak frequency style