|
JSampler v0.8a |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jsampler.DefaultSamplerChannelModel
public class DefaultSamplerChannelModel
This class provides default implementation of the SamplerChannelModel interface.
Note that all methods that begin with setBackend alter the settings
on the backend side.
| Constructor Summary | |
|---|---|
DefaultSamplerChannelModel(SamplerChannel channel)
Creates a new instance of DefaultSamplerChannelModel using the
specified channel settings. |
|
| Method Summary | |
|---|---|
void |
addBackendFxSend(int midiCtrl)
Schedules a new task for adding a new effect send on the backend side. |
void |
addBackendFxSend(int midiCtrl,
java.lang.String name)
Schedules a new task for adding a new effect send on the backend side. |
void |
addEffectSendsListener(EffectSendsListener l)
Registers the specified listener for receiving event messages. |
void |
addFxSend(FxSend fxSend)
Adds the specified effect send. |
void |
addSamplerChannelListener(SamplerChannelListener l)
Registers the specified listener for receiving event messages. |
void |
duplicateBackendChannel()
Schedules a new task for duplicating the channel. |
protected void |
fireFxSendAdded(FxSend fxSend)
Notifies listeners that the specified effect send has been added to the channel. |
protected void |
fireFxSendRemoved(FxSend fxSend)
Notifies listeners that the specified effect send has been removed. |
protected void |
fireFxSendUpdated(FxSend fxSend)
Notifies listeners that the specified effect send has been updated. |
protected void |
fireSamplerChannelChanged()
Notifies listeners that the sampler channel settings has changed. |
protected void |
fireSamplerChannelChanged(SamplerChannelEvent e)
Notifies listeners that the sampler channel settings has changed. |
protected void |
fireStreamCountChanged()
Notifies listeners that the number of active disk streams has changed. |
protected void |
fireStreamCountChanged(SamplerChannelEvent e)
Notifies listeners that the number of active disk streams has changed. |
protected void |
fireVoiceCountChanged()
Notifies listeners that the number of active voices has changed. |
protected void |
fireVoiceCountChanged(SamplerChannelEvent e)
Notifies listeners that the number of active voices has changed. |
int |
getChannelId()
Gets the sampler channel number. |
SamplerChannel |
getChannelInfo()
Gets the current settings of the sampler channel. |
FxSend |
getFxSend(int index)
Gets the effect send at the specified position. |
FxSend |
getFxSendById(int fxSendId)
Gets the effect send with the specified ID. |
int |
getFxSendCount()
Gets the current number of effect sends. |
FxSend[] |
getFxSends()
Gets the current list of effect sends. |
int |
getStreamCount()
Gets the number of active disk streams. |
int |
getVoiceCount()
Gets the number of active voices. |
void |
loadBackendInstrument(java.lang.String filename,
int InstrIndex)
Schedules a new task for loading and assigning the specified instrument to the sampler channel represented by this model. |
void |
removeAllFxSends()
Removes all effect sends from this channel. |
void |
removeBackendFxSend(int fxSendId)
Schedules a new task for removing the specified effect send on the backend side. |
void |
removeEffectSendsListener(EffectSendsListener l)
Removes the specified listener. |
FxSend |
removeFxSend(int index)
Removes the effect send at the specified position. |
boolean |
removeFxSendById(int fxSendId)
Removes the specified effect send. |
void |
removeSamplerChannelListener(SamplerChannelListener l)
Removes the specified listener. |
void |
resetBackendChannel()
Schedules a new task for reseting the channel. |
void |
setBackendAudioOutputChannel(int audioSrc,
int audioDst)
Sets the destination of the destination of the specified audio channel. |
void |
setBackendAudioOutputDevice(int deviceId)
Schedules a new task for setting (on the backend side) the audio output device of the channel represented by this model. |
void |
setBackendEngineType(java.lang.String engine)
Schedules a new task for setting the sampler engine type to be used. |
void |
setBackendFxSendAudioOutputChannel(int fxSend,
int audioSrc,
int audioDst)
Sets the destination of an effect send's audio channel. |
void |
setBackendFxSendLevel(int fxSend,
float level)
Sets the volume of the specified effect send. |
void |
setBackendFxSendMidiController(int fxSend,
int midiCtrl)
Sets the MIDI controller of the specified effect send. |
void |
setBackendFxSendName(int fxSend,
java.lang.String name)
Sets the name of the specified effect send. |
void |
setBackendMidiInputChannel(int channel)
Schedules a new task for setting (on the backend side) the MIDI channel that the channel represented by this model should listen to. |
void |
setBackendMidiInputDevice(int deviceId)
Schedules a new task for setting on the backend side the MIDI input device of the channel represented by this model. |
void |
setBackendMidiInputPort(int port)
Schedules a new task for setting (on the backend side) the MIDI input port of the channel represented by this model. |
void |
setBackendMidiInstrumentMap(int mapId)
Schedules a new task for assigning (on the backend side) the specified MIDI instrument map to this sampler channel. |
void |
setBackendMute(boolean mute)
Schedules a new task for setting the mute mode of the channel. |
void |
setBackendSolo(boolean solo)
Schedules a new task for setting on the backend side the solo mode of the channel. |
void |
setBackendVolume(float volume)
Schedules a new task for setting the channel volume on the backend side. |
void |
setChannelInfo(SamplerChannel channel)
Sets the current settings of the sampler channel. |
void |
setStreamCount(int count)
Sets the number of active disk streams. |
void |
setVoiceCount(int count)
Sets the number of active voices. |
void |
updateFxSend(FxSend fxSend)
Updates the specified effect send. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultSamplerChannelModel(SamplerChannel channel)
DefaultSamplerChannelModel using the
specified channel settings.
channel - A non-null SamplerChannel instance containing the current
settings of the channel which will be represented by this sampler channel model.
java.lang.IllegalArgumentException - If channel is null.| Method Detail |
|---|
public void addSamplerChannelListener(SamplerChannelListener l)
addSamplerChannelListener in interface SamplerChannelModell - The SamplerChannelListener to register.public void removeSamplerChannelListener(SamplerChannelListener l)
removeSamplerChannelListener in interface SamplerChannelModell - The SamplerChannelListener to remove.public void addEffectSendsListener(EffectSendsListener l)
addEffectSendsListener in interface SamplerChannelModell - The EffectSendsListener to register.public void removeEffectSendsListener(EffectSendsListener l)
removeEffectSendsListener in interface SamplerChannelModell - The EffectSendsListener to remove.public int getChannelId()
getChannelId in interface SamplerChannelModelpublic SamplerChannel getChannelInfo()
getChannelInfo in interface SamplerChannelModelSamplerChannel instance containing
the current settings of the sampler channel.public void setChannelInfo(SamplerChannel channel)
setChannelInfo in interface SamplerChannelModelchannel - A SamplerChannel instance containing
the new settings for this sampler channel.
java.lang.IllegalArgumentException - If channel is null.public int getStreamCount()
getStreamCount in interface SamplerChannelModelpublic void setStreamCount(int count)
setStreamCount in interface SamplerChannelModelcount - The new number of active disk streams.public int getVoiceCount()
getVoiceCount in interface SamplerChannelModelpublic void setVoiceCount(int count)
setVoiceCount in interface SamplerChannelModelcount - The new number of active voices.public void setBackendEngineType(java.lang.String engine)
setBackendEngineType in interface SamplerChannelModelengine - The name of the engine type to be used.public void setBackendMute(boolean mute)
setBackendMute in interface SamplerChannelModelmute - Specifies the mute mode. If true the channel is muted, else
the channel is unmuted.public void setBackendSolo(boolean solo)
setBackendSolo in interface SamplerChannelModelsolo - Specifies the solo mode. If true the channel is soloed, else
the channel is unsoloed.public void setBackendVolume(float volume)
setBackendVolume in interface SamplerChannelModelvolume - Specifies the new volume value.public void setBackendMidiInputDevice(int deviceId)
setBackendMidiInputDevice in interface SamplerChannelModeldeviceId - Specifies the numerical ID of the MIDI input device to be set.public void setBackendMidiInputPort(int port)
setBackendMidiInputPort in interface SamplerChannelModelport - Specifies the number of the MIDI input port.public void setBackendMidiInputChannel(int channel)
setBackendMidiInputChannel in interface SamplerChannelModelchannel - Specifies the MIDI channel that the channel
represented by this model should listen to.public void setBackendAudioOutputDevice(int deviceId)
setBackendAudioOutputDevice in interface SamplerChannelModeldeviceId - Specifies the numerical ID of the audio output device to be set.
public void setBackendAudioOutputChannel(int audioSrc,
int audioDst)
setBackendAudioOutputChannel in interface SamplerChannelModelaudioSrc - The numerical ID of the sampler channel's audio
output channel, which should be rerouted.audioDst - The audio channel of the selected audio output device
where audioSrc should be routed to.public void setBackendMidiInstrumentMap(int mapId)
setBackendMidiInstrumentMap in interface SamplerChannelModelmapId - Specify the numerical ID of the MIDI instrument
map that should be assigned to this sampler
channel or -1 to remove the current map binding.
public void loadBackendInstrument(java.lang.String filename,
int InstrIndex)
loadBackendInstrument in interface SamplerChannelModelfilename - The file name of the instrument to be loaded.InstrIndex - The index of the instrument in the instrument file to be loaded.public void resetBackendChannel()
resetBackendChannel in interface SamplerChannelModelpublic void duplicateBackendChannel()
duplicateBackendChannel in interface SamplerChannelModelpublic void addBackendFxSend(int midiCtrl)
addBackendFxSend in interface SamplerChannelModelmidiCtrl - Defines the MIDI controller, which
will be able alter the effect send level.
public void addBackendFxSend(int midiCtrl,
java.lang.String name)
addBackendFxSend in interface SamplerChannelModelmidiCtrl - Defines the MIDI controller, which
will be able alter the effect send level.name - The name of the effect send entity.
The name does not have to be unique.public void addFxSend(FxSend fxSend)
addFxSend in interface SamplerChannelModelfxSend - The effect send to be added.public void removeBackendFxSend(int fxSendId)
removeBackendFxSend in interface SamplerChannelModelfxSendId - The ID of the effect send to remove.public FxSend getFxSend(int index)
getFxSend in interface SamplerChannelModelindex - The index of the effect send to be returned.
public FxSend getFxSendById(int fxSendId)
getFxSendById in interface SamplerChannelModelfxSendId - The ID of the effect send to return.
null
if there is no effect send with ID fxSendId.public FxSend removeFxSend(int index)
removeFxSend in interface SamplerChannelModelindex - The position of the effect send to remove.
public boolean removeFxSendById(int fxSendId)
removeFxSendById in interface SamplerChannelModelfxSendId - The ID of the effect send to remove.
true if the effect send is removed successfully, false
if the channel does not contain effect send with ID fxSendId.public void removeAllFxSends()
removeAllFxSends in interface SamplerChannelModelpublic void updateFxSend(FxSend fxSend)
updateFxSend in interface SamplerChannelModelfxSend - The effect send to update.public int getFxSendCount()
getFxSendCount in interface SamplerChannelModelpublic FxSend[] getFxSends()
getFxSends in interface SamplerChannelModel
public void setBackendFxSendName(int fxSend,
java.lang.String name)
setBackendFxSendName in interface SamplerChannelModelfxSend - The numerical ID of the effect send.name - The new name of the effect send entity.
public void setBackendFxSendAudioOutputChannel(int fxSend,
int audioSrc,
int audioDst)
setBackendFxSendAudioOutputChannel in interface SamplerChannelModelfxSend - The numerical ID of the effect send entity to be rerouted.audioSrc - The numerical ID of the effect send's audio output channel,
which should be rerouted.audioDst - The audio channel of the selected audio output device
where audioSrc should be routed to.
public void setBackendFxSendMidiController(int fxSend,
int midiCtrl)
setBackendFxSendMidiController in interface SamplerChannelModelfxSend - The numerical ID of the effect send.midiCtrl - The MIDI controller which shall be
able to modify the effect send's send level.
public void setBackendFxSendLevel(int fxSend,
float level)
setBackendFxSendLevel in interface SamplerChannelModelfxSend - The numerical ID of the effect
send, which volume should be changed.level - The new volume value.protected void fireSamplerChannelChanged()
protected void fireSamplerChannelChanged(SamplerChannelEvent e)
protected void fireStreamCountChanged()
protected void fireStreamCountChanged(SamplerChannelEvent e)
protected void fireVoiceCountChanged()
protected void fireVoiceCountChanged(SamplerChannelEvent e)
protected void fireFxSendAdded(FxSend fxSend)
protected void fireFxSendRemoved(FxSend fxSend)
protected void fireFxSendUpdated(FxSend fxSend)
|
JSampler v0.8a |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||