annotate widgets/ActivityLog.h @ 1127:9fb8dfd7ce4c spectrogram-minor-refactor

Fix threshold in spectrogram -- it wasn't working in the last release. There is a new protocol for this. Formerly the threshold parameter had a range from -50dB to 0 with the default at -50, and -50 treated internally as "no threshold". However, there was a hardcoded, hidden internal threshold for spectrogram colour mapping at -80dB with anything below this being rounded to zero. Now the threshold parameter has range -81 to -1 with the default at -80, -81 is treated internally as "no threshold", and there is no hidden internal threshold. So the default behaviour is the same as before, an effective -80dB threshold, but it is now possible to change this in both directions. Sessions reloaded from prior versions may look slightly different because, if the session says there should be no threshold, there will now actually be no threshold instead of having the hidden internal one. Still need to do something in the UI to make it apparent that the -81dB setting removes the threshold entirely. This is at least no worse than the previous, also obscured, magic -50dB setting.
author Chris Cannam
date Mon, 01 Aug 2016 16:21:01 +0100
parents 299d0ffebb38
children 05d614f6e46d
rev   line source
Chris@502 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
Chris@502 2
Chris@502 3 /*
Chris@502 4 Sonic Visualiser
Chris@502 5 An audio file viewer and annotation editor.
Chris@502 6 Centre for Digital Music, Queen Mary, University of London.
Chris@502 7 This file copyright 2009 QMUL.
Chris@502 8
Chris@502 9 This program is free software; you can redistribute it and/or
Chris@502 10 modify it under the terms of the GNU General Public License as
Chris@502 11 published by the Free Software Foundation; either version 2 of the
Chris@502 12 License, or (at your option) any later version. See the file
Chris@502 13 COPYING included with this distribution for more information.
Chris@502 14 */
Chris@502 15
Chris@502 16 #ifndef _ACTIVITY_LOG_H_
Chris@502 17 #define _ACTIVITY_LOG_H_
Chris@502 18
Chris@502 19 #include <QDialog>
Chris@502 20 #include <QString>
Chris@502 21
Chris@502 22 class QListView;
Chris@502 23 class QStringListModel;
Chris@502 24
Chris@502 25 class ActivityLog : public QDialog
Chris@502 26 {
Chris@502 27 Q_OBJECT
Chris@502 28
Chris@502 29 public:
Chris@502 30 ActivityLog();
Chris@502 31 ~ActivityLog();
Chris@502 32
Chris@502 33 public slots:
Chris@502 34 void activityHappened(QString);
Chris@505 35 void scrollToEnd();
Chris@502 36
Chris@502 37 private:
Chris@502 38 QListView *m_listView;
Chris@502 39 QStringListModel *m_model;
Chris@503 40 QString m_prevName;
Chris@502 41 };
Chris@502 42
Chris@502 43 #endif