public final class MidiChannelImpl extends Object implements MidiChannel
MidiChannel
implementationConstructor and Description |
---|
MidiChannelImpl(int channel,
Receiver receiver,
VoiceStatus voiceStatus)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
allNotesOff()
Indicate 'All notes off' message to the
MidiChannel |
void |
allSoundOff()
Indicate 'All sound off' message to the
MidiChannel |
void |
controlChange(int controller,
int value)
Set 'Controller' status to the
MidiChannel |
int |
getChannelPressure()
Get 'Channel pressure' status of the
MidiChannel |
int |
getController(int controller)
Get 'Controller' status of the
MidiChannel |
boolean |
getMono()
Get 'Mono' status of the
MidiChannel |
boolean |
getMute()
Get 'Mute' status of the
MidiChannel |
boolean |
getOmni()
Get 'Omni' status of the
MidiChannel |
int |
getPitchBend()
Get 'Pitch bend' status of the
MidiChannel |
int |
getPolyPressure(int noteNumber)
Get 'Poly pressure' status of the
MidiChannel |
int |
getProgram()
Get 'Program' status of the
MidiChannel |
boolean |
getSolo()
Get 'Solo' status of the
MidiChannel |
boolean |
localControl(boolean on)
Set 'Local control' status to the
MidiChannel |
void |
noteOff(int noteNumber)
Indicate 'Note off' message to the
MidiChannel |
void |
noteOff(int noteNumber,
int velocity)
Indicate 'Note off' message to the
MidiChannel |
void |
noteOn(int noteNumber,
int velocity)
Indicate 'Note on' message to the
MidiChannel |
void |
programChange(int program)
Set 'Program' status to the
MidiChannel |
void |
programChange(int bank,
int program)
Set 'Bank' and 'Program' status to the
MidiChannel |
void |
resetAllControllers()
Indicate 'Reset all controllers' message to the
MidiChannel |
void |
setChannelPressure(int pressure)
Set 'Channel pressure' status to the
MidiChannel |
void |
setMono(boolean on)
Set 'Mono' status to the
MidiChannel |
void |
setMute(boolean mute)
Set 'Mute' status to the
MidiChannel |
void |
setOmni(boolean on)
Set 'Omni' status to the
MidiChannel |
void |
setPitchBend(int bend)
Set 'Pitch bend' status to the
MidiChannel |
void |
setPolyPressure(int noteNumber,
int pressure)
Set 'Poly pressure' status to the
MidiChannel |
void |
setSolo(boolean soloState)
Set 'Solo' status to the
MidiChannel |
public MidiChannelImpl(int channel, @NonNull Receiver receiver, @NonNull VoiceStatus voiceStatus)
channel
- the channel 0-15receiver
- the receiverpublic void allNotesOff()
MidiChannel
MidiChannel
allNotesOff
in interface MidiChannel
public void allSoundOff()
MidiChannel
MidiChannel
allSoundOff
in interface MidiChannel
public void resetAllControllers()
MidiChannel
MidiChannel
resetAllControllers
in interface MidiChannel
public void noteOff(int noteNumber)
MidiChannel
MidiChannel
noteOff
in interface MidiChannel
noteNumber
- the note numberpublic void noteOff(int noteNumber, int velocity)
MidiChannel
MidiChannel
noteOff
in interface MidiChannel
noteNumber
- the note numbervelocity
- the note off velocitypublic void noteOn(int noteNumber, int velocity)
MidiChannel
MidiChannel
noteOn
in interface MidiChannel
noteNumber
- the note numbervelocity
- the note on velocitypublic int getChannelPressure()
MidiChannel
MidiChannel
getChannelPressure
in interface MidiChannel
public void setChannelPressure(int pressure)
MidiChannel
MidiChannel
setChannelPressure
in interface MidiChannel
pressure
- the channel pressurepublic int getController(int controller)
MidiChannel
MidiChannel
getController
in interface MidiChannel
controller
- the controller IDpublic void controlChange(int controller, int value)
MidiChannel
MidiChannel
controlChange
in interface MidiChannel
controller
- the controller IDvalue
- the controller valuepublic int getProgram()
MidiChannel
MidiChannel
getProgram
in interface MidiChannel
public void programChange(int program)
MidiChannel
MidiChannel
programChange
in interface MidiChannel
program
- the programpublic void programChange(int bank, int program)
MidiChannel
MidiChannel
programChange
in interface MidiChannel
bank
- the bankprogram
- the programpublic boolean getMono()
MidiChannel
MidiChannel
getMono
in interface MidiChannel
public void setMono(boolean on)
MidiChannel
MidiChannel
setMono
in interface MidiChannel
on
- 'Mono' statuspublic boolean getMute()
MidiChannel
MidiChannel
getMute
in interface MidiChannel
public void setMute(boolean mute)
MidiChannel
MidiChannel
setMute
in interface MidiChannel
mute
- 'Mute' statuspublic boolean getOmni()
MidiChannel
MidiChannel
getOmni
in interface MidiChannel
public void setOmni(boolean on)
MidiChannel
MidiChannel
setOmni
in interface MidiChannel
on
- 'Omni' statuspublic int getPitchBend()
MidiChannel
MidiChannel
getPitchBend
in interface MidiChannel
public void setPitchBend(int bend)
MidiChannel
MidiChannel
setPitchBend
in interface MidiChannel
bend
- 'Pitch bend' amount 0-8191-16383public int getPolyPressure(int noteNumber)
MidiChannel
MidiChannel
getPolyPressure
in interface MidiChannel
noteNumber
- the note numberpublic void setPolyPressure(int noteNumber, int pressure)
MidiChannel
MidiChannel
setPolyPressure
in interface MidiChannel
noteNumber
- the note numberpressure
- the note pressurepublic boolean getSolo()
MidiChannel
MidiChannel
getSolo
in interface MidiChannel
public void setSolo(boolean soloState)
MidiChannel
MidiChannel
setSolo
in interface MidiChannel
soloState
- 'Solo' statuspublic boolean localControl(boolean on)
MidiChannel
MidiChannel
localControl
in interface MidiChannel
on
- 'Local control' status