Mercurial > hg > svgui
diff layer/SpectrumLayer.h @ 1386:fc3d89f88690 spectrogramparam
Use log-frequency rather than log-bin for calculating x coord in spectrum. This has the advantage that frequency positions don't move when we change the window size or oversampling ratio, but it does give us an unhelpfully large amount of space for very low frequencies - to be considered
author | Chris Cannam |
---|---|
date | Mon, 12 Nov 2018 11:34:34 +0000 |
parents | 86f319dd6ab9 |
children | 900bed394f5a |
line wrap: on
line diff
--- a/layer/SpectrumLayer.h Thu Nov 08 12:55:36 2018 +0000 +++ b/layer/SpectrumLayer.h Mon Nov 12 11:34:34 2018 +0000 @@ -125,6 +125,14 @@ void setupFFT(); + virtual double getBinForFrequency(double freq) const; + virtual double getFrequencyForBin(double bin) const; + + virtual double getXForBin(const LayerGeometryProvider *, double bin) + const override; + virtual double getBinForX(const LayerGeometryProvider *, double x) + const override; + virtual void getBiasCurve(BiasCurve &) const override; BiasCurve m_biasCurve;