diff data/model/FFTModel.cpp @ 1136:e94719f941ba tony-2.0-integration

Return maximum through getNormalizedMagnitudesAt to avoid having to make more than one call
author Chris Cannam
date Tue, 20 Oct 2015 12:54:06 +0100
parents e994747fb9dd
children 444d133b5ab7
line wrap: on
line diff
--- a/data/model/FFTModel.cpp	Wed Oct 14 10:19:48 2015 +0100
+++ b/data/model/FFTModel.cpp	Tue Oct 20 12:54:06 2015 +0100
@@ -155,7 +155,7 @@
     return true;
 }
 
-bool
+float
 FFTModel::getNormalizedMagnitudesAt(int x, float *values, int minbin, int count) const
 {
     if (!getMagnitudesAt(x, values, minbin, count)) return false;
@@ -169,7 +169,7 @@
             values[i] /= max;
         }
     }
-    return true;
+    return max;
 }
 
 bool