annotate plugin/transform/TransformDescription.h @ 339:ba30f4a3e3be

* Some work on correct alignment when moving panes during playback * Overhaul alignment for playback frame values (view manager now always refers to reference-timeline values, only the play source deals in playback model timeline values) * When making a selection, ensure the selection regions shown in other panes (and used for playback constraints if appropriate) are aligned correctly. This may be the coolest feature ever implemented in any program ever.
author Chris Cannam
date Thu, 22 Nov 2007 14:17:19 +0000
parents 3179d8b29336
children d7c41483af8f 94fc0591ea43
rev   line source
Chris@329 1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
Chris@329 2
Chris@329 3 /*
Chris@329 4 Sonic Visualiser
Chris@329 5 An audio file viewer and annotation editor.
Chris@329 6 Centre for Digital Music, Queen Mary, University of London.
Chris@329 7 This file copyright 2006-2007 Chris Cannam and QMUL.
Chris@329 8
Chris@329 9 This program is free software; you can redistribute it and/or
Chris@329 10 modify it under the terms of the GNU General Public License as
Chris@329 11 published by the Free Software Foundation; either version 2 of the
Chris@329 12 License, or (at your option) any later version. See the file
Chris@329 13 COPYING included with this distribution for more information.
Chris@329 14 */
Chris@329 15
Chris@329 16 #ifndef _TRANSFORM_DESCRIPTION_H_
Chris@329 17 #define _TRANSFORM_DESCRIPTION_H_
Chris@329 18
Chris@329 19 #include "Transform.h"
Chris@329 20
Chris@329 21 #include <QString>
Chris@329 22
Chris@329 23 #include <vector>
Chris@329 24
Chris@329 25 /**
Chris@329 26 * Metadata associated with a transform.
Chris@329 27 *
Chris@329 28 * The transform ID is the same as that used in the Transform class.
Chris@329 29 * It is intended to be computer-referenceable and unique within the
Chris@329 30 * application.
Chris@329 31 *
Chris@329 32 * The name is intended to be human readable. In principle it doesn't
Chris@329 33 * have to be unique, but the factory that creates these objects
Chris@329 34 * should add suffixes to ensure that it is, all the same (just to
Chris@329 35 * avoid user confusion).
Chris@329 36 *
Chris@329 37 * The friendly name is a shorter version of the name.
Chris@329 38 *
Chris@329 39 * The type is also intended to be user-readable, for use in menus.
Chris@329 40 */
Chris@329 41
Chris@329 42 struct TransformDescription
Chris@329 43 {
Chris@329 44 TransformDescription() { }
Chris@329 45 TransformDescription(QString _type, QString _category,
Chris@329 46 TransformId _identifier, QString _name,
Chris@329 47 QString _friendlyName, QString _description,
Chris@329 48 QString _maker, QString _units, bool _configurable) :
Chris@329 49 type(_type), category(_category),
Chris@329 50 identifier(_identifier), name(_name),
Chris@329 51 friendlyName(_friendlyName), description(_description),
Chris@329 52 maker(_maker), units(_units), configurable(_configurable) { }
Chris@329 53
Chris@329 54 QString type; // e.g. feature extraction plugin
Chris@329 55 QString category; // e.g. time > onsets
Chris@329 56 TransformId identifier; // e.g. vamp:vamp-aubio:aubioonset
Chris@329 57 QString name; // plugin's name if 1 output, else "name: output"
Chris@329 58 QString friendlyName; // short text for layer name
Chris@329 59 QString description; // sentence describing transform
Chris@329 60 QString maker;
Chris@329 61 QString units;
Chris@329 62 bool configurable;
Chris@329 63
Chris@329 64 bool operator<(const TransformDescription &od) const {
Chris@329 65 return (name < od.name);
Chris@329 66 };
Chris@329 67 };
Chris@329 68
Chris@329 69 typedef std::vector<TransformDescription> TransformList;
Chris@329 70
Chris@329 71 #endif