diff src/BTrack.h @ 26:e4d5f045064d develop

Replaced the pointers to arrays in BTrack with vectors
author Adam <adamstark.uk@gmail.com>
date Mon, 27 Jan 2014 23:54:18 +0000
parents deb49a2590f3
children 7af87d3f2ce2
line wrap: on
line diff
--- a/src/BTrack.h	Mon Jan 27 23:20:13 2014 +0000
+++ b/src/BTrack.h	Mon Jan 27 23:54:18 2014 +0000
@@ -23,6 +23,7 @@
 #define __BTRACK_H
 
 #include "OnsetDetectionFunction.h"
+#include <vector>
 
 //=======================================================================
 /** The main beat tracking class and the interface to the BTrack
@@ -172,9 +173,11 @@
     
     //=======================================================================
 	// buffers
-    double *onsetDF;                        /**< to hold onset detection function */
+    
+    std::vector<double> onsetDF;            /**< to hold onset detection function */
+    std::vector<double> cumulativeScore;    /**< to hold cumulative score */
+    
     double resampledOnsetDF[512];           /**< to hold resampled detection function */
-    double *cumulativeScore;                /**<  to hold cumulative score */
 	
     double acf[512];                        /**<  to hold autocorrelation function */