comparison layer/SpectrogramLayer.h @ 1379:b6cca362bbf4 spectrogramparam

Experimental oversampling param
author Chris Cannam
date Tue, 06 Nov 2018 13:36:04 +0000
parents d79e21855aef
children a18e78b9c78b
comparison
equal deleted inserted replaced
1378:f08a3b8cdb9d 1379:b6cca362bbf4
109 int getWindowSize() const; 109 int getWindowSize() const;
110 110
111 void setWindowHopLevel(int level); 111 void setWindowHopLevel(int level);
112 int getWindowHopLevel() const; 112 int getWindowHopLevel() const;
113 113
114 void setOversampling(int oversampling);
115 int getOversampling() const;
116
114 void setWindowType(WindowType type); 117 void setWindowType(WindowType type);
115 WindowType getWindowType() const; 118 WindowType getWindowType() const;
116 119
117 /** 120 /**
118 * Set the gain multiplier for sample values in this view. 121 * Set the gain multiplier for sample values in this view.
244 247
245 int m_channel; 248 int m_channel;
246 int m_windowSize; 249 int m_windowSize;
247 WindowType m_windowType; 250 WindowType m_windowType;
248 int m_windowHopLevel; 251 int m_windowHopLevel;
252 int m_oversampling;
249 float m_gain; 253 float m_gain;
250 float m_initialGain; 254 float m_initialGain;
251 float m_threshold; 255 float m_threshold;
252 float m_initialThreshold; 256 float m_initialThreshold;
253 int m_colourRotation; 257 int m_colourRotation;
298 if (m_windowHopLevel == 0) return m_windowSize; 302 if (m_windowHopLevel == 0) return m_windowSize;
299 else if (m_windowHopLevel == 1) return (m_windowSize * 3) / 4; 303 else if (m_windowHopLevel == 1) return (m_windowSize * 3) / 4;
300 else return m_windowSize / (1 << (m_windowHopLevel - 1)); 304 else return m_windowSize / (1 << (m_windowHopLevel - 1));
301 } 305 }
302 306
303 int getFFTOversampling() const; 307 int getFFTSize() const; // m_windowSize * getOversampling()
304 int getFFTSize() const; // m_windowSize * getFFTOversampling()
305 308
306 FFTModel *m_fftModel; 309 FFTModel *m_fftModel;
307 FFTModel *getFFTModel() const { return m_fftModel; } 310 FFTModel *getFFTModel() const { return m_fftModel; }
308 Dense3DModelPeakCache *m_wholeCache; 311 Dense3DModelPeakCache *m_wholeCache;
309 Dense3DModelPeakCache *m_peakCache; 312 Dense3DModelPeakCache *m_peakCache;