diff data/model/WaveformOversampler.cpp @ 1544:ca43af0dcab7 zoom

Profiler
author Chris Cannam
date Fri, 28 Sep 2018 18:08:04 +0100
parents fa67fbbff8fc
children 074b860a7828
line wrap: on
line diff
--- a/data/model/WaveformOversampler.cpp	Fri Sep 28 18:08:00 2018 +0100
+++ b/data/model/WaveformOversampler.cpp	Fri Sep 28 18:08:04 2018 +0100
@@ -14,6 +14,8 @@
 
 #include "WaveformOversampler.h"
 
+#include "base/Profiler.h"
+
 #include "data/model/DenseTimeValueModel.h"
 
 floatvec_t
@@ -23,6 +25,8 @@
                                         sv_frame_t sourceFrameCount,
                                         int oversampleBy)
 {
+    Profiler profiler("WaveformOversampler::getOversampledData");
+    
     // Oversampled at a fixed ratio of m_filterRatio
     floatvec_t fixedRatio = getFixedRatioData(source, channel,
                                               sourceStartFrame,
@@ -54,6 +58,8 @@
                                        sv_frame_t sourceStartFrame,
                                        sv_frame_t sourceFrameCount)
 {
+    Profiler profiler("WaveformOversampler::getFixedRatioData");
+    
     sv_frame_t sourceLength = source->getEndFrame();
     
     if (sourceStartFrame + sourceFrameCount > sourceLength) {