Mercurial > hg > qm-dsp
diff dsp/chromagram/Chromagram.cpp @ 34:ad645e404d0c
* Add range of normalise options to chromagram
* bit of tidying
author | cannam |
---|---|
date | Tue, 22 Jan 2008 17:27:07 +0000 |
parents | 8bb764969d50 |
children | 114e833c07ac |
line wrap: on
line diff
--- a/dsp/chromagram/Chromagram.cpp Mon Jan 21 18:02:47 2008 +0000 +++ b/dsp/chromagram/Chromagram.cpp Tue Jan 22 17:27:07 2008 +0000 @@ -25,7 +25,7 @@ m_FMin = Config.min; // min freq m_FMax = Config.max; // max freq m_BPO = Config.BPO; // bins per octave - isNormalised = Config.isNormalised; // true if frame normalisation is required + m_normalise = Config.normalise; // if frame normalisation is required // No. of constant Q bins m_uK = ( unsigned int ) ceil( m_BPO * log(m_FMax/m_FMin)/log(2.0)); @@ -157,8 +157,7 @@ } } - if( isNormalised ) - unityNormalise( m_chromadata ); + MathUtilities::normalise(m_chromadata, m_BPO, m_normalise); return m_chromadata; }