Skip to main content

Function: useMIDIInput()

useMIDIInput(midiAccess, onNoteOnEvent?, onNoteOffEvent?, onPitchBendEvent?): void

Defined in: hooks/useMIDIInput.ts:21

Hooks for handling note on/off events. To be used with useMIDIAccess. Internally uses useMIDIMessage.

Parameters

midiAccess

MIDIAccess | null

onNoteOnEvent?

(note, velocity) => void

onNoteOffEvent?

(note) => void

onPitchBendEvent?

(msb, lsb) => void

Returns

void