Apply a pitch bend to all notes currently sounding on the channel. No bend is 00 40 (64 in decimal), maximum downward bend is 00 00, maximum upward bend is 7F 7F. The Least Significant Byte (lsb) is optional (default value is 0), as it is useful only for fine adjustment. You can not use it with play_note, play_chord or play_broken_chord: you must manage yourself the Note ON and Note OFF events, and put the bend between.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(MIDI_file), | intent(inout) | :: | self | |||
integer, | intent(in) | :: | channel | |||
integer, | intent(in), | optional | :: | lsb | ||
integer, | intent(in) | :: | msb |
subroutine Pitch_Bend(self, channel, lsb, msb) class(MIDI_file), intent(inout) :: self integer, intent(in) :: channel ! 8 bits (0..15) integer, optional, intent(in) :: lsb ! 8 bits (0..127) integer, intent(in) :: msb ! 8 bits (0..127) integer(int8) :: octets(0:2) call self%delta_time(0) octets(0) = int(z'E0', int8) + checked_int8(channel, upper=15) if (present(lsb)) then octets(1) = checked_int8(lsb) else octets(1) = 0_int8 end if octets(2) = checked_int8(msb) write(self%unit, iostat=self%status) octets end subroutine Pitch_Bend