diff data/model/FFTModel.cpp @ 1186:12a8daa89970 spectrogram-minor-refactor

Mid-refactor to pull out the bulk of paintDrawBuffer into chunks
author Chris Cannam
date Mon, 13 Jun 2016 16:17:44 +0100
parents 444d133b5ab7
children 6d09ad2ab21f
line wrap: on
line diff
--- a/data/model/FFTModel.cpp	Wed Apr 27 11:04:32 2016 +0100
+++ b/data/model/FFTModel.cpp	Mon Jun 13 16:17:44 2016 +0100
@@ -149,23 +149,6 @@
     return true;
 }
 
-float
-FFTModel::getNormalizedMagnitudesAt(int x, float *values, int minbin, int count) const
-{
-    if (!getMagnitudesAt(x, values, minbin, count)) return false;
-    if (count == 0) count = getHeight();
-    float max = 0.f;
-    for (int i = 0; i < count; ++i) {
-        if (values[i] > max) max = values[i];
-    }
-    if (max > 0.f) {
-        for (int i = 0; i < count; ++i) {
-            values[i] /= max;
-        }
-    }
-    return max;
-}
-
 bool
 FFTModel::getPhasesAt(int x, float *values, int minbin, int count) const
 {