#include <Sampler.h>
Public Member Functions | |
void | SetEngineType (String EngineType) throw (Exception) |
Assign a sampler engine type to this sampler channel. | |
void | SetAudioOutputDevice (AudioOutputDevice *pDevice) throw (Exception) |
Connect this sampler channel to an audio output device, that is an instance of an audio output driver. | |
void | SetMidiInputDevice (MidiInputDevice *pDevice) throw (Exception) |
Connect this sampler channel to a MIDI input device. | |
void | SetMidiInputPort (int MidiPort) throw (Exception) |
Connect this sampler channel to a MIDI input port. | |
void | SetMidiInputChannel (midi_chan_t MidiChannel) |
Define on which MIDI channel(s) this sampler channel should listen to. | |
void | SetMidiInput (MidiInputDevice *pDevice, int iMidiPort, midi_chan_t MidiChannel=midi_chan_all) throw (Exception) |
Connect this sampler channel to a MIDI input triplet. | |
EngineChannel * | GetEngineChannel () |
Returns the EngineChannel object that was deployed on this sampler channel appropriate to the given sampler engine type. | |
midi_chan_t | GetMidiInputChannel () |
Returns the MIDI input channel to which this sampler channel is currently connected to. | |
int | GetMidiInputPort () |
Returns the MIDI input port number to which this sampler channel is currently connected to. | |
AudioOutputDevice * | GetAudioOutputDevice () |
Returns the audio output device to which this sampler channel is currently connected to. | |
MidiInputDevice * | GetMidiInputDevice () |
Returns the MIDI input device to which this sampler channel is currently connected to. | |
uint | Index () |
Returns the index number of this sampler channel within the Sampler instance. | |
Sampler * | GetSampler () |
Returns the sampler to which this channel belongs. | |
void | AddEngineChangeListener (EngineChangeListener *l) |
Registers the specified listener to be notified when the engine type of this sampler channel is changed. | |
void | RemoveEngineChangeListener (EngineChangeListener *l) |
Removes the specified listener. | |
void | RemoveAllEngineChangeListeners () |
Removes the specified listener. | |
void | fireEngineToBeChanged () |
Notifies listeners that the engine type of this sampler channel is going to be changed soon. | |
void | fireEngineChanged () |
Notifies listeners that the engine type of this sampler channel is changed. | |
Protected Member Functions | |
SamplerChannel (Sampler *pS) | |
virtual | ~SamplerChannel () |
MidiInputPort * | __GetMidiInputDevicePort (int iMidiPort) |
Getting MIDI input device port given its index number. | |
Protected Attributes | |
Sampler * | pSampler |
EngineChannel * | pEngineChannel |
AudioOutputDevice * | pAudioOutputDevice |
MidiInputDevice * | pMidiInputDevice |
int | iIndex |
Friends | |
class | Sampler |
Encapsulates a channel of a specific sampler engine type, one connection to a MIDI input device and one connection to an audio output device. You cannot create an instance of this class on your own, you have to use the AddSamplerChannel() method of the Sampler object to create a new sampler channel.
Definition at line 49 of file Sampler.h.
LinuxSampler::SamplerChannel::SamplerChannel | ( | Sampler * | pS | ) | [protected] |
virtual LinuxSampler::SamplerChannel::~SamplerChannel | ( | ) | [protected, virtual] |
MidiInputPort* LinuxSampler::SamplerChannel::__GetMidiInputDevicePort | ( | int | iMidiPort | ) | [protected] |
Getting MIDI input device port given its index number.
void LinuxSampler::SamplerChannel::AddEngineChangeListener | ( | EngineChangeListener * | l | ) |
Registers the specified listener to be notified when the engine type of this sampler channel is changed.
void LinuxSampler::SamplerChannel::fireEngineChanged | ( | ) |
Notifies listeners that the engine type of this sampler channel is changed.
void LinuxSampler::SamplerChannel::fireEngineToBeChanged | ( | ) |
Notifies listeners that the engine type of this sampler channel is going to be changed soon.
AudioOutputDevice* LinuxSampler::SamplerChannel::GetAudioOutputDevice | ( | ) |
Returns the audio output device to which this sampler channel is currently connected to.
EngineChannel* LinuxSampler::SamplerChannel::GetEngineChannel | ( | ) |
Returns the EngineChannel object that was deployed on this sampler channel appropriate to the given sampler engine type.
midi_chan_t LinuxSampler::SamplerChannel::GetMidiInputChannel | ( | ) |
Returns the MIDI input channel to which this sampler channel is currently connected to.
MidiInputDevice* LinuxSampler::SamplerChannel::GetMidiInputDevice | ( | ) |
Returns the MIDI input device to which this sampler channel is currently connected to.
int LinuxSampler::SamplerChannel::GetMidiInputPort | ( | ) |
Returns the MIDI input port number to which this sampler channel is currently connected to.
Sampler* LinuxSampler::SamplerChannel::GetSampler | ( | ) |
Returns the sampler to which this channel belongs.
uint LinuxSampler::SamplerChannel::Index | ( | ) |
Returns the index number of this sampler channel within the Sampler instance.
void LinuxSampler::SamplerChannel::RemoveAllEngineChangeListeners | ( | ) |
Removes the specified listener.
void LinuxSampler::SamplerChannel::RemoveEngineChangeListener | ( | EngineChangeListener * | l | ) |
Removes the specified listener.
void LinuxSampler::SamplerChannel::SetAudioOutputDevice | ( | AudioOutputDevice * | pDevice | ) | throw (Exception) |
Connect this sampler channel to an audio output device, that is an instance of an audio output driver.
If this sampler channel was already connected to an audio output device, then the old connection will automatically be removed before.
pDevice | - audio output device to connect to |
Exception | in case the audio device is tried to be changed while the sampler channel is used by a host plugin (e.g. VST, AU, DSSI, LV2) which don't allow to change the audio output device |
Assign a sampler engine type to this sampler channel.
EngineType | - type of the engine to use |
Exception | - if EngineType is invalid |
void LinuxSampler::SamplerChannel::SetMidiInput | ( | MidiInputDevice * | pDevice, | |
int | iMidiPort, | |||
midi_chan_t | MidiChannel = midi_chan_all | |||
) | throw (Exception) |
Connect this sampler channel to a MIDI input triplet.
pDevice | - MIDI input device to connect to | |
iMidiPort | - MIDI port to connect to | |
MidiChannel | - optional: MIDI channel on which the sampler channel should listen to (default: listen on all MIDI channels) |
Exception | in case the MIDI port is tried to be changed while the sampler channel is being used by a host plugin (e.g. VST, AU, DSSI, LV2) which don't allow to change the MIDI port |
void LinuxSampler::SamplerChannel::SetMidiInputChannel | ( | midi_chan_t | MidiChannel | ) |
Define on which MIDI channel(s) this sampler channel should listen to.
By default, that is after creation of a new sampler channel, the sampler channel will listen to all MIDI channels.
MidiChannel | - MIDI channel to listen |
void LinuxSampler::SamplerChannel::SetMidiInputDevice | ( | MidiInputDevice * | pDevice | ) | throw (Exception) |
Connect this sampler channel to a MIDI input device.
pDevice | - MIDI input device to connect to |
Exception | in case the MIDI device is tried to be changed while the sampler channel is being used by a host plugin (e.g. VST, AU, DSSI, LV2) which don't allow to change the MIDI port or even device |
void LinuxSampler::SamplerChannel::SetMidiInputPort | ( | int | MidiPort | ) | throw (Exception) |
Connect this sampler channel to a MIDI input port.
MidiPort | - MIDI port to connect to |
Exception | in case the MIDI port is tried to be changed while the sampler channel is being used by a host plugin (e.g. VST, AU, DSSI, LV2) which don't allow to change the MIDI port |
int LinuxSampler::SamplerChannel::iIndex [protected] |
Sampler* LinuxSampler::SamplerChannel::pSampler [protected] |