MIKMIDINoteCommand
Objective-C
@interface MIKMIDINoteCommand : MIKMIDIChannelVoiceCommand
Swift
class MIKMIDINoteCommand : MIKMIDIChannelVoiceCommand
A MIDI note on message.
-
Convenience method for creating a note on command.
Declaration
Objective-C
+ (nonnull instancetype)noteCommandWithNote:(NSUInteger)note velocity:(NSUInteger)velocity channel:(UInt8)channel isNoteOn:(BOOL)isNoteOn timestamp:(nullable NSDate *)timestamp;
Swift
convenience init(note: UInt, velocity: UInt, channel: UInt8, isNoteOn: Bool, timestamp: Date?)
Parameters
note
The note number for the command. Must be between 0 and 127.
velocity
The velocity for the command. Must be between 0 and 127.
channel
The channel for the command. Must be between 0 and 15.
isNoteOn
YES if the command should be a note on command, NO if it should be a note off command.
timestamp
The timestamp for the command. Pass nil to use the current date/time.
Return Value
An initialized MIKMIDINoteCommand instance.
-
Convenience method for creating a note command.
Declaration
Objective-C
+ (nonnull instancetype)noteCommandWithNote:(NSUInteger)note velocity:(NSUInteger)velocity channel:(UInt8)channel isNoteOn:(BOOL)isNoteOn midiTimeStamp:(MIDITimeStamp)timestamp;
Swift
convenience init(note: UInt, velocity: UInt, channel: UInt8, isNoteOn: Bool, midiTimeStamp timestamp: MIDITimeStamp)
Parameters
note
The note number for the command. Must be between 0 and 127.
velocity
The velocity for the command. Must be between 0 and 127.
channel
The channel for the command. Must be between 0 and 15.
isNoteOn
YES if the command should be a note on command, NO if it should be a note off command.
timestamp
The MIDITimestamp for the command.
Return Value
An initialized MIKMIDINoteCommand instance.
-
The note number for the message. In the range 0-127.
Declaration
Objective-C
@property (nonatomic, readonly) NSUInteger note;
Swift
var note: UInt { get }
-
Velocity of the note on message. In the range 0-127.
Declaration
Objective-C
@property (nonatomic, readonly) NSUInteger velocity;
Swift
var velocity: UInt { get }
-
YES if the receiver is a note on, NO if it is a note off.
Declaration
Objective-C
@property (nonatomic, readonly, getter=isNoteOn) BOOL noteOn;
Swift
var isNoteOn: Bool { get }