diff options
author | Tim E. Real <termtech@rogers.com> | 2011-06-19 01:26:26 +0000 |
---|---|---|
committer | Tim E. Real <termtech@rogers.com> | 2011-06-19 01:26:26 +0000 |
commit | 02941424387a064301372c12bda3e8c3ab3fee45 (patch) | |
tree | e4cdea4400d8a34060a1c4d2b32da8e7ef46ab90 /muse2/muse/synth.h | |
parent | 448d81436ed8c2bc501506c2663a9bdb8c0dd023 (diff) |
Major work, all synthesizers. Other fixes. Please see ChangeLog.
Diffstat (limited to 'muse2/muse/synth.h')
-rw-r--r-- | muse2/muse/synth.h | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/muse2/muse/synth.h b/muse2/muse/synth.h index 88fa70b8..0c48a231 100644 --- a/muse2/muse/synth.h +++ b/muse2/muse/synth.h @@ -22,6 +22,9 @@ #include <QFileInfo> +// Current version of saved midistate data. +#define SYNTH_MIDI_STATE_SAVE_VERSION 2 + //class QMenu; class PopupMenu; @@ -105,17 +108,25 @@ class Mess; //--------------------------------------------------------- // SynthIF // synth instance interface +// NOTICE: If implementing sysex support, be sure to make a unique ID and use +// it to filter out unrecognized sysexes. Headers should be constructed as: +// MUSE_SYNTH_SYSEX_MFG_ID The MusE SoftSynth Manufacturer ID byte (0x7C) found in midi.h +// 0xNN The synth's unique ID byte //--------------------------------------------------------- class SynthIF { + protected: SynthI* synti; - + public: //SynthIF() {} SynthIF(SynthI* s) { synti = s; } virtual ~SynthIF() {} + // This is only a kludge required to support old songs' midistates. Do not use in any new synth. + virtual int oldMidiStateHeader(const unsigned char** /*data*/) const { return 0; } + virtual bool initGui() = 0; virtual void guiHeartBeat() = 0; virtual bool guiVisible() const = 0; @@ -280,6 +291,10 @@ class SynthI : public AudioTrack, public MidiDevice, //--------------------------------------------------------- // MessSynthIF // mess synthesizer instance +// NOTICE: If implementing sysex support, be sure to make a unique ID and use +// it to filter out unrecognized sysexes. Headers should be constructed as: +// MUSE_SYNTH_SYSEX_MFG_ID The MusE SoftSynth Manufacturer ID byte (0x7C) found in midi.h +// 0xNN The synth's unique ID byte //--------------------------------------------------------- class MessSynthIF : public SynthIF { @@ -290,6 +305,9 @@ class MessSynthIF : public SynthIF { MessSynthIF(SynthI* s) : SynthIF(s) { _mess = 0; } virtual ~MessSynthIF() { } + // This is only a kludge required to support old songs' midistates. Do not use in any new synth. + virtual int oldMidiStateHeader(const unsigned char** data) const; + virtual bool initGui() { return true; } virtual void guiHeartBeat() { } virtual bool guiVisible() const { return false; } |