Class MidiIn

The MidiIn class is an implementation of IMidiIn, which receives MIDI messages from a connected MIDI port and distributes in a more easily consumable format.

Hierarchy

  • MidiIn

Implements

Constructors

  • Parameters

    • port: MIDIInput

      The MIDI port which data gets received from, see the MidiAccess class.

    Returns MidiIn

Accessors

  • get port(): MIDIInput
  • The MIDI port which data gets received from, see the MidiAccess class.

    Setting this property automatically unsubscribes from any previously connected MIDI port, and also automatically subscribes to the newly set MIDI port.

    Returns MIDIInput

  • set port(value: MIDIInput): void
  • Parameters

    • value: MIDIInput

    Returns void

  • get typeName(): string
  • Returns the name of this type. This can be used rather than instanceof which is sometimes unreliable.

    Returns string

Methods

  • The receiveData method allows for raw MIDI message data to be passed in, which will then be analysed, and trigger an event for whichever MIDI event type it corresponds to.

    Parameters

    Returns void

Generated using TypeDoc