Web MIDI Synths

Hi,
A few months ago, Chrome's decision to ban the Windows GS Wavetable 
Synth highlighted the need for MIDI output devices that are neither 
hardware nor installed plugins. If they want to reach the widest 
possible audience, web application programmers can't expect their users 
to pre-install anything. Those of us programming such apps were left 
high and dry. The Windows GS Wavetable Synth was only available to 
Windows users anyway...

In answer to this problem, I've adapted the code for two existing 
software synths so that they implement the Web MIDI API for Output 
Devices, and have embedded these in a host application [1], [2] to show 
that they actually work.
The synthesizers can quite easily be lifted out and used by any web app 
that sends MIDI messages to an output device (see [3] and [4]).

There are two main categories of Web MIDI Synth: Those that implement 
Standard MIDI Controls, and those that don't. I've adapted one of each.

The Standard Web MIDI Synth (Sf2Synth1 [5]) is working fine, but really 
needs optimising by people who know more about programming the Web Audio 
API than I do. It also needs testing with other soundFonts...
Loading times will always be a problem when working with soundFonts, but 
I''ve tried to mitigate the problem by separating the synth code from 
the soundFont. Host applications only need to load presets that they are 
actually going to use (e.g. a grand piano). It also has to be said, that 
browsers cache soundFonts, so applications start much faster the second 
time.
Note that Standard Web MIDI Synths can be used interchangeably with the 
hardware devices provided by browser implementations of the Web MIDI API.

The Non-Standard Web MIDI Synth (cwMIDISynth [6]).
Software synths that implement the interface I've designed for this 
synth can be used in any web application. There are no restrictions on 
the controls the synth programmer can use, they just have to be declared 
properly. MIDI can control anything.
So, if you have programmed a software synthesizer, and want it to be 
used in a web application, maybe you could implement the interface?

Any discussion would be very welcome, of course.

All the best,
James

[1] GitHub: https://github.com/notator/WebMIDISynthHost
[2] Web page: 
http://james-ingram-act-two.de/open-source/WebMIDISynthHost/host.html
[3] Simple demo: 
http://james-ingram-act-two.de/open-source/SimpleMIDISynthHost/host.html
[4] Simple demo: 
http://james-ingram-act-two.de/open-source/SimpleSoundFontSynthHost/host.html
[5] Adapted from gree's sf2synth.js at https://github.com/gree/sf2synth.js
[6] Adapted from Chris Wilson's MIDI-Synth at
https://webaudiodemos.appspot.com/midi-synth/index.html

Received on Saturday, 28 November 2015 11:42:27 UTC