Mercurial > hg > qm-dsp
comparison dsp/onsets/DetectionFunction.cpp @ 102:37449f085a4c
Fix compiler warnings
author | Chris Cannam |
---|---|
date | Thu, 13 Jun 2013 10:23:09 +0100 |
parents | e5907ae6de17 |
children | f976d7609700 |
comparison
equal
deleted
inserted
replaced
101:452615c4bab4 | 102:37449f085a4c |
---|---|
100 // data directly), we will have to use the next smallest power of | 100 // data directly), we will have to use the next smallest power of |
101 // two from the block size. Results may vary accordingly! | 101 // two from the block size. Results may vary accordingly! |
102 | 102 |
103 int actualLength = MathUtilities::previousPowerOfTwo(m_dataLength); | 103 int actualLength = MathUtilities::previousPowerOfTwo(m_dataLength); |
104 | 104 |
105 if (actualLength != m_dataLength) { | 105 if (actualLength != (int)m_dataLength) { |
106 // Pre-fill mag and phase vectors with zero, as the FFT output | 106 // Pre-fill mag and phase vectors with zero, as the FFT output |
107 // will not fill the arrays | 107 // will not fill the arrays |
108 for (int i = actualLength/2; i < m_dataLength/2; ++i) { | 108 for (int i = actualLength/2; i < (int)m_dataLength/2; ++i) { |
109 m_magnitude[i] = 0; | 109 m_magnitude[i] = 0; |
110 m_thetaAngle[0] = 0; | 110 m_thetaAngle[0] = 0; |
111 } | 111 } |
112 } | 112 } |
113 | 113 |