annotate base/PlayParameterRepository.h @ 184:5a916fee6d2d

* Handle generator transforms (plugins whose channel count isn't dependent on number of audio inputs, as they have none) * Be less keen to suspend writing FFT data in spectrogram repaint -- only do it if we find we actually need to query the FFT data (i.e. we aren't repainting an area that hasn't been generated at all yet)
author Chris Cannam
date Tue, 10 Oct 2006 19:04:57 +0000
parents 82f529a08cf3
children 41d64b873d87
rev   line source
Chris@49 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
Chris@28 2
Chris@28 3 /*
Chris@52 4 Sonic Visualiser
Chris@52 5 An audio file viewer and annotation editor.
Chris@52 6 Centre for Digital Music, Queen Mary, University of London.
Chris@52 7 This file copyright 2006 Chris Cannam.
Chris@28 8
Chris@52 9 This program is free software; you can redistribute it and/or
Chris@52 10 modify it under the terms of the GNU General Public License as
Chris@52 11 published by the Free Software Foundation; either version 2 of the
Chris@52 12 License, or (at your option) any later version. See the file
Chris@52 13 COPYING included with this distribution for more information.
Chris@28 14 */
Chris@28 15
Chris@28 16 #ifndef _PLAY_PARAMETER_REPOSITORY_H_
Chris@28 17 #define _PLAY_PARAMETER_REPOSITORY_H_
Chris@28 18
Chris@28 19 class PlayParameters;
Chris@28 20 class Model;
Chris@28 21
Chris@28 22 #include <map>
Chris@28 23
Chris@29 24 #include <QObject>
Chris@29 25
Chris@29 26 class PlayParameterRepository : public QObject
Chris@28 27 {
Chris@29 28 Q_OBJECT
Chris@29 29
Chris@28 30 public:
Chris@145 31 static PlayParameterRepository *getInstance();
Chris@28 32
Chris@28 33 virtual ~PlayParameterRepository();
Chris@28 34
Chris@30 35 void addModel(const Model *model);
Chris@30 36 void removeModel(const Model *model);
Chris@30 37
Chris@30 38 PlayParameters *getPlayParameters(const Model *model) const;
Chris@28 39
Chris@28 40 void clear();
Chris@28 41
Chris@29 42 signals:
Chris@29 43 void playParametersChanged(PlayParameters *);
Chris@57 44 void playPluginIdChanged(const Model *, QString);
Chris@57 45 void playPluginConfigurationChanged(const Model *, QString);
Chris@29 46
Chris@29 47 protected slots:
Chris@29 48 void playParametersChanged();
Chris@57 49 void playPluginIdChanged(QString);
Chris@57 50 void playPluginConfigurationChanged(QString);
Chris@29 51
Chris@28 52 protected:
Chris@57 53 typedef std::map<const Model *, PlayParameters *> ModelParameterMap;
Chris@57 54 ModelParameterMap m_playParameters;
Chris@28 55
Chris@28 56 static PlayParameterRepository *m_instance;
Chris@28 57 };
Chris@28 58
Chris@28 59 #endif