summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/instrument_info.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2013-01-20 08:56:00 +0000
committerDavid Robillard <d@drobilla.net>2013-01-20 08:56:00 +0000
commit4e6d0c9e61b62931a4a2120b548f0ff02a966351 (patch)
tree17c395d18338fb92d7af62fa635a8e957d523f93 /libs/ardour/ardour/instrument_info.h
parent0ebad4279b765d3fbe85649e9ef29e5b61c1d162 (diff)
Show matching controller name in automation lane header.
Completely eliminate static MIDI controller name code. Reduce dependency on midnam_patch.h (which would have saved me several hours if I did it earlier). Store controller name numbers as an integer. Keep controller names in a map keyed by int instead of a list for fast lookup. More cleanup of MIDI::Name code. git-svn-id: svn://localhost/ardour2/branches/3.0@13927 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/ardour/instrument_info.h')
-rw-r--r--libs/ardour/ardour/instrument_info.h17
1 files changed, 13 insertions, 4 deletions
diff --git a/libs/ardour/ardour/instrument_info.h b/libs/ardour/ardour/instrument_info.h
index f83b2c0632..8691db24e5 100644
--- a/libs/ardour/ardour/instrument_info.h
+++ b/libs/ardour/ardour/instrument_info.h
@@ -22,11 +22,19 @@
#include <string>
#include <stdint.h>
+#include <boost/weak_ptr.hpp>
+
#include "pbd/signals.h"
-#include "midi++/midnam_patch.h"
+#include "evoral/Parameter.hpp"
-#include <boost/weak_ptr.hpp>
+namespace MIDI {
+namespace Name {
+class ChannelNameSet;
+class Patch;
+typedef std::list<boost::shared_ptr<Patch> > PatchNameList;
+}
+}
namespace ARDOUR {
@@ -41,13 +49,14 @@ class InstrumentInfo {
void set_internal_instrument (boost::shared_ptr<ARDOUR::Processor>);
std::string get_patch_name (uint16_t bank, uint8_t program, uint8_t channel) const;
+ std::string get_controller_name (Evoral::Parameter param) const;
std::string get_instrument_name () const;
boost::shared_ptr<MIDI::Name::ChannelNameSet> get_patches (uint8_t channel);
PBD::Signal0<void> Changed;
- static const MIDI::Name::PatchBank::PatchNameList& general_midi_patches();
+ static const MIDI::Name::PatchNameList& general_midi_patches();
private:
std::string external_instrument_model;
@@ -58,7 +67,7 @@ class InstrumentInfo {
boost::shared_ptr<MIDI::Name::ChannelNameSet> plugin_programs_to_channel_name_set (boost::shared_ptr<Processor> p);
std::string get_plugin_patch_name (boost::shared_ptr<ARDOUR::Processor>, uint16_t bank, uint8_t program, uint8_t channel) const;
- static MIDI::Name::PatchBank::PatchNameList _gm_patches;
+ static MIDI::Name::PatchNameList _gm_patches;
};
} /* namespace ARDOUR */