OpenWareLaboratory
|
Public Member Functions | |
virtual void | allNotesOff () |
virtual void | channelPressure (MidiMessage msg) |
virtual void | controlChange (MidiMessage msg) |
float | frequencyToNote (float freq) |
virtual void | gate (bool state)=0 |
uint8_t | getNote () |
Set note in whole semitones. More... | |
float | getPitchBend () |
Get pitch bend amount in semitones. More... | |
float | getPitchBendRange () |
Get pitch bend range in semitones. More... | |
float | getTuning () |
virtual void | modulate (MidiMessage msg) |
virtual void | noteOff (MidiMessage msg) |
virtual void | noteOn (MidiMessage msg) |
float | noteToFrequency (float note) |
virtual void | pitchbend (MidiMessage msg) |
virtual void | polyKeyPressure (MidiMessage msg) |
virtual void | process (MidiMessage msg) |
void | setDynamicRange (float db) |
virtual void | setFrequency (float freq)=0 |
virtual void | setGain (float gain)=0 |
virtual void | setModulation (float modulation) |
void | setModulationDepthRange (float range) |
Set modulation depth range, from 0 to 1.0. More... | |
virtual void | setNote (uint8_t note) |
Set note in whole semitones and update frequency. More... | |
virtual void | setParameter (uint8_t parameter_id, float value) |
Set a Synth parameter. More... | |
virtual void | setPitchBend (float pb) |
Set pitch bend amount in semitones and update frequency. More... | |
void | setPitchBendRange (float range) |
Set pitch bend range in semitones. More... | |
virtual void | setPressure (float pressure) |
void | setTuning (float value) |
Set frequency in Hertz for middle A (defaults to Stuttgart pitch, A440, 440 Hz) More... | |
virtual void | sustain (MidiMessage msg) |
virtual void | trigger ()=0 |
float | velocityToGain (float v) |
virtual | ~AbstractSynth () |
Protected Attributes | |
float | mod_range = 0.5/127.0f |
uint8_t | note = 60 |
float | pb = 0 |
float | pb_range = 2/8192.0f |
float | tuning = 440 |
Definition at line 9 of file AbstractSynth.h.
|
inlinevirtual |
Definition at line 17 of file AbstractSynth.h.
|
inlinevirtual |
Definition at line 100 of file AbstractSynth.h.
References Synth::gate().
Referenced by controlChange().
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 88 of file AbstractSynth.h.
References MidiMessage::getChannelPressure(), and setPressure().
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 82 of file AbstractSynth.h.
References allNotesOff(), MidiMessage::getControllerNumber(), MidiMessage::getControllerValue(), MIDI_ALL_NOTES_OFF, MIDI_CC_MODULATION, and setModulation().
|
inline |
Definition at line 107 of file AbstractSynth.h.
References tuning.
|
pure virtualinherited |
Referenced by allNotesOff(), noteOff(), and noteOn().
|
inline |
|
inline |
|
inline |
Get pitch bend range in semitones.
Definition at line 56 of file AbstractSynth.h.
References pb_range.
|
inline |
Definition at line 24 of file AbstractSynth.h.
References tuning.
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 94 of file AbstractSynth.h.
References MidiMessage::getControllerValue(), mod_range, and setModulation().
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 79 of file AbstractSynth.h.
References Synth::gate().
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 73 of file AbstractSynth.h.
References Synth::gate(), MidiMessage::getNote(), MidiMessage::getVelocity(), note, noteToFrequency(), pb, Synth::setFrequency(), Synth::setGain(), setNote(), and VelocityCurve::velocityToGain().
|
inline |
Definition at line 110 of file AbstractSynth.h.
Referenced by noteOn(), setNote(), and setPitchBend().
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 97 of file AbstractSynth.h.
References MidiMessage::getPitchBend(), pb_range, and setPitchBend().
|
inlinevirtual |
Reimplemented from MidiProcessor.
Definition at line 91 of file AbstractSynth.h.
References MidiMessage::getPolyKeyPressure(), and setPressure().
|
inlinevirtualinherited |
Definition at line 22 of file MidiProcessor.h.
References MidiProcessor::channelPressure(), MidiProcessor::controlChange(), MidiMessage::isChannelPressure(), MidiMessage::isControlChange(), MidiMessage::isNoteOff(), MidiMessage::isNoteOn(), MidiMessage::isPitchBend(), MidiMessage::isPolyKeyPressure(), MidiProcessor::noteOff(), MidiProcessor::noteOn(), MidiProcessor::pitchbend(), and MidiProcessor::polyKeyPressure().
|
inlineinherited |
Definition at line 20 of file VelocityCurve.h.
|
pure virtualinherited |
Referenced by noteOn(), setNote(), and setPitchBend().
|
pure virtualinherited |
Referenced by noteOn().
|
inlinevirtual |
Definition at line 104 of file AbstractSynth.h.
Referenced by controlChange(), and modulate().
|
inline |
Set modulation depth range, from 0 to 1.0.
Definition at line 69 of file AbstractSynth.h.
References mod_range.
|
inlinevirtual |
Set note in whole semitones and update frequency.
Definition at line 36 of file AbstractSynth.h.
References note, noteToFrequency(), pb, and Synth::setFrequency().
Referenced by noteOn().
|
inlinevirtualinherited |
|
inlinevirtual |
Set pitch bend amount in semitones and update frequency.
Definition at line 49 of file AbstractSynth.h.
References note, noteToFrequency(), pb, and Synth::setFrequency().
Referenced by pitchbend().
|
inline |
Set pitch bend range in semitones.
Does not update the frequency; effective from next pitch bend change
Definition at line 63 of file AbstractSynth.h.
|
inlinevirtual |
Definition at line 105 of file AbstractSynth.h.
Referenced by channelPressure(), and polyKeyPressure().
|
inline |
Set frequency in Hertz for middle A (defaults to Stuttgart pitch, A440, 440 Hz)
Definition at line 21 of file AbstractSynth.h.
References tuning.
|
inlinevirtualinherited |
Reimplemented in VoiceAllocator< SynthVoice, VOICES >, and VoiceAllocator< SynthVoice, 1 >.
Definition at line 16 of file MidiProcessor.h.
|
pure virtualinherited |
|
inlineinherited |
Definition at line 25 of file VelocityCurve.h.
Referenced by noteOn().
|
protected |
Definition at line 14 of file AbstractSynth.h.
Referenced by modulate(), and setModulationDepthRange().
|
protected |
Definition at line 11 of file AbstractSynth.h.
Referenced by getNote(), noteOn(), noteToFrequency(), setNote(), and setPitchBend().
|
protected |
Definition at line 12 of file AbstractSynth.h.
Referenced by getPitchBend(), noteOn(), setNote(), and setPitchBend().
|
protected |
Definition at line 13 of file AbstractSynth.h.
Referenced by getPitchBendRange(), and pitchbend().
|
protected |
Definition at line 15 of file AbstractSynth.h.
Referenced by frequencyToNote(), getTuning(), noteToFrequency(), and setTuning().