Roadmap for version 3.x
Enhancements Still Remaining
Publish TypeScript definitions to DefinitelyTyped when v3 is stable (they are currently available in the
distdirectory)Adjust
InputChannel.EVENTSto include allcontrolchange-xxxeventsAdd
inputconnected,inputdisconnected,outputconnectedandoutputdisconnectedevents.There is something in
InputChannel.test.jsthat prevents the tests from running correctly inOutput.test.jsA combined CC0 / CC32 / ProgChange method to call program changes with bank selection in a single method
The callback for
WebMidi.addListener()andInput.addListener()should probably have both atargetand aportproperty when the target is not the same as the port. Perhaps both should be kept everywhere for consistency.
Enhancement Already Baked In
Added triggering of
portschangedevent inWebMidiobject (v3.0.2).Add
filteroption to allow listening to only a subset of events (e.g. specific controller change or NRPN messages, discussed in PR #88)Add a way to forward inbound messages on an
Inputobject to anOutput(to behave like a physical MIDI THRU port). This could be expanded to a more elaborate filtering and routing system (example)Add mechanism to Generate TypeScript type definitions (.d.ts files)
Add
getNoteState()method toInputChannelso it it is possible to check if a note is currently playing or not. This allows to check for chords when a noteon message is received.Properly handle when a laptop's lid is closed then reopened (Issue #140)
As suggested by users, allow sending MSB and LSB at once when sending control change messages (Issue #57). This would have to be done for CC messages 0-31 which all have a matching LSB.
Rewrite the NRPN parsing mechanism in InputChannel. I do not think it works correctly. Here are starting points:
Allow
sendSysex()to acceptUint8Array(Issue #124, forum thread) or perhaps to accept aMessageobject that can be built from aUint8Array(this needs to be carefully examined)Add a
MessageobjectAdd the ability to set default values for attack velocity, release velocity, etc. ( see forum discussion)
Various utility methods should probably be stashed in a
Utilsclass (e.g. getCcNameByNumber(), etc.)Add convenience method to convert float and 7 bit:
to7bit()andtoNormalized()Add the ability to individually transpose
Input,Output,InputChannelandOutputChannel.Add
InputChannelandOutputChannelobjects (Issue #20)Use ES6+ modern syntax and add default export so library can be imported with
import(Issues #49 and #89)Move to Rollup for packaging the library (Issue #61)
Drop support for Bower (Issue #60)
Extend a proper event library to allow for modern event support (probably djipevents).
Implement port
statechangeevents (connectedanddisconnected)Make
WebMidia singleton (see example here)WebMidi should dispatch 'enabled' and 'disabled' event
Check that disable() really does disable everything
Add methods for channel mode messages
Implement
clear()method (Issue #52) [this will automatically work when browsers add support for it but will show a warning in the console until then).Added the new (software) parameter for
requestMIDIAccess[this will automatically work when browsers add support for it).Emit events for all channel mode messages
Add
statusByteanddataBytesproperties to the event triggered when receiving messages (#109)Deprecate the ability to send on all channels (default behaviour). This clogs up the MIDI stream and I do not really see a good use case for it.
Create a
Noteobject withdurationandvelocitypropertyAdd official support for Node.js (Issue #15)
Allow specifying different note durations and velocities in
playNote()when using arrays (Issue #75 and #90). [this is now possible withNoteobjects].Complete test suite for all objects
Add
sendRaw()method accepting either list of integers orUint8Array.Allow
send()to acceptUint8Array