feat(plotview): Recommend a decimation based on the tuner BW

This commit is contained in:
schneider
2016-08-31 21:38:04 +01:00
parent 4833c8938a
commit d3754785b0
7 changed files with 24 additions and 2 deletions

View File

@@ -34,7 +34,7 @@
SpectrogramPlot::SpectrogramPlot(std::shared_ptr<SampleSource<std::complex<float>>> src) : Plot(src), inputSource(src), tuner(this)
{
setFFTSize(512);
zoomLevel = 0;
zoomLevel = 1;
powerMax = 0.0f;
powerMin = -50.0f;
@@ -236,6 +236,7 @@ void SpectrogramPlot::tunerMoved()
{
tunerTransform->setFrequency(getTunerPhaseInc());
tunerTransform->setTaps(getTunerTaps());
tunerTransform->setRelativeBandwith(tuner.deviation() * 2.0 / getStride());
// TODO: for invalidating traceplot cache, this shouldn't really go here
QPixmapCache::clear();