diff Matcher.h @ 29:cd0ffe6b1e68

Make distance scale a parameter as well
author Chris Cannam
date Fri, 31 Oct 2014 13:03:16 +0000
parents 9f60d097f0b2
children
line wrap: on
line diff
--- a/Matcher.h	Fri Oct 31 11:41:42 2014 +0000
+++ b/Matcher.h	Fri Oct 31 13:03:16 2014 +0000
@@ -62,6 +62,7 @@
             sampleRate(rate_),
             frameNorm(NormaliseFrameToSum1),
             distanceNorm(DistanceMetric::NormaliseDistanceToLogSum),
+            distanceScale(90.0),
             useSpectralDifference(true),
             useChromaFrequencyMap(false),
             hopTime(hopTime_),
@@ -81,6 +82,12 @@
         /** Type of distance metric normalisation */
         DistanceMetric::DistanceNormalisation distanceNorm;
 
+        /** Scaling factor for distance metric; must guarantee that the
+         *  final value fits in the data type used, that is, unsigned
+         *  char.
+         */
+        double distanceScale;
+
         /** Flag indicating whether or not the half-wave rectified
          *  spectral difference should be used in calculating the
          *  distance metric for pairs of audio frames, instead of the
@@ -141,12 +148,6 @@
     /** Configuration parameters */
     Parameters params;
 
-    /** Scaling factor for distance metric; must guarantee that the
-     *  final value fits in the data type used, that is, unsigned
-     *  char.
-     */
-    double scale;
-
     /** Width of the search band in FFT frames (see <code>blockTime</code>) */
     int blockSize;