Optionalchannelsvoices only these channels (0 to 15) and drops the rest, to render one stem of a file
Optionalgainmaster level, 0 to 1
Optionalmaxhard cap on rendered seconds; longer tails are cut
Optionalsampleoutput sample rate in Hz
Optionalsoundfontvoices every note from these samples; without one the built-in synth plays
Optionalsynthvoices the file through a MidiSynth instead: a registered engine name ('retro:mt32'), a
factory, or an ordered list tried until one works. Takes precedence over soundfont, which
stays the next choice when the synth cannot be used (see onMidiSynthFallback).
A Standard MIDI File rendered to stereo PCM frames, the same bridge the RPG Maker player crosses with an offline audio context: browsers cannot decode MIDI, so the file is synthesized once, faster than real time, and what comes out is an ordinary buffered track with a loop region, ready for a
Channel, a seek and a pitch and pan control that MIDI bytes on their own could never answer.Two voicings. With a
SoundFontevery note plays the real instrument sample for its bank, program, key and velocity, with the font's loops, envelope, tuning and pan. Without one a small General MIDI approximation voices it instead: each program family maps to a waveform and envelope recipe and channel 10 is a noise and sine drum kit. Both honour channel volume, expression and pan per note; the synth keeps melody, rhythm and structure while its timbre stays approximate, which is why a SoundFont makes such a difference. Pitch bend is voiced as the bend in effect when each note starts (two semitones either way); a bend that moves while a note holds does not glide it.