diff options
author | Daniel Schürmann <daschuer@mixxx.org> | 2019-05-14 01:07:15 +0200 |
---|---|---|
committer | Daniel Schürmann <daschuer@mixxx.org> | 2019-05-14 01:07:15 +0200 |
commit | 3174fb0ff567b938b9bc94deb8c92bf1cd2470bf (patch) | |
tree | 6ffcb747bee6266de379191fb8add48973f0ec57 /lib | |
parent | 08367f5361171fda53e3df44965d5eb6359d4125 (diff) |
Add commented debug output of fractional keys.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/qm-dsp/dsp/keydetection/GetKeyMode.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/qm-dsp/dsp/keydetection/GetKeyMode.cpp b/lib/qm-dsp/dsp/keydetection/GetKeyMode.cpp index 5a82edfef2..7407c43feb 100644 --- a/lib/qm-dsp/dsp/keydetection/GetKeyMode.cpp +++ b/lib/qm-dsp/dsp/keydetection/GetKeyMode.cpp @@ -268,8 +268,10 @@ int GetKeyMode::process(double *PCMData) // m_Keys[1] is C center 1 / 3 + 1 = 1
// m_Keys[4] is D center 4 / 3 + 1 = 2
// '+ 1' because we number keys 1-24, not 0-23.
- key = MathUtilities::getMax( m_Keys, 2* m_BPO, &dummy ) / 3 + 1;
+ int maxBin = MathUtilities::getMax( m_Keys, 2* m_BPO, &dummy );
+ key = maxBin / 3 + 1;
+// std::cout << "fractional key pre-sorting: " << (maxBin + 2) / 3.0 << std::endl;
// std::cout << "key pre-sorting: " << key << std::endl;
|