1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134
|
% SONIVOXRENDER(1) sonivoxrender 0.0.0 | Sonivox MIDI File Renderer
% Pedro López-Cabanillas <plcl@users.sf.net>
# NAME
**sonivoxrender** — Render MIDI song files into raw PCM audio
# SYNOPSIS
| **sonivoxrender** [**-h|-\-help**] [**-v|-\-version**] [**-d|-\-dls** _soundfont_] [**-r|-\-reverb** _0..4_] [**-w|-\-wet** _0..32767_] [**-n|-\-dry** _0..32767_] [**-c|-\-chorus** _0..4_] [**-l|-\-level** _0..32767_] [**-g|-\-gain** _0..196_] [**-V|-\-Verbosity** _0..5_] [**-R|-\-reverb-post-mix**] [**-C|-\-chorus-post-mix**] [**-s|-\-sndlib** _1..3_] _song_file_
# DESCRIPTION
This program is a MIDI file renderer based on the sonivox synthesizer library.
It reads .MID (Standard MIDI Files), .RMI (RIFF-RMID), and .XMF (Extensible Music Files) file formats, and writes an audio stream to the standard output as raw 16 bit stereo PCM samples.
## Options
-h, -\-help
: Prints brief usage information.
-v, -\-version
: Prints the version numbers.
-d, -\-dls _soundfont_
: Optional DLS or SF2 soundfont file name. If not provided, it uses an internal embedded soundfont.
-r, -\-reverb _reverb_preset_
: Reverb preset between 0 and 4: 0=no, 1=large hall, 2=hall, 3=chamber, 4=room.
-w, -\-wet _reverb_wet_
: Reverb wet level between 0 and 32767.
-n, -\-dry _reverb_dry_
: Reverb dry level between 0 and 32767.
-c, -\-chorus _chorus_preset_
: Chorus preset between 0 and 4: 0=no, 1..4=presets.
-l, -\-level _chorus_level_
: Chorus level between 0 and 32767.
-g, -\-gain _master_gain_
: Master gain between 0 and 196, default is 100 (+0dB). The number is relative to 100, in 1dB increments, e.g. 120 = +20dB, 80 = -20dB.
-V, -\-Verbosity _verbosity_
: Verbosity level between 0 and 5, where 0=no, 1..5=severity levels.
-R, -\-reverb-post-mix
: Ignore CC91 reverb send level. The reverb effect will apply to mixed output audio, which is the old behavior.
-C, -\-chorus-post-mix
: Ignore CC93 chorus send level. See also **-\-reverb-post-mix**.
-s, -\-sndlib _index_
: EAS sound library to use:
* 1: wt_200k_G (default) - WT-only bank, used in Android devices. Also named "Common".
Support 22050 Hz and 44100 Hz sample rates, 8-bit and 16-bit samples.
* 2: GMdblib-3 - FM-only bank. Support all sample rates. Sample bit depth does not matter here.
* 3: hybrid_22khz_mcu - Hybrid bank. Use WT synth for drums and FM for melodic instruments.
This bank is a combination of `GMdblib-3` and `Sonic_20Khz_Drums`.
Support 22050 Hz sample rate and 8-bit samples only.
**Note:** This option does not affect DLS/SF2. They will always use the DLS synth engine. If the selected sound library is not compatible with the build configuration, the program will fail with an error message.
## Arguments
_song_file_
: Input [**MID|RMI|XMF**] file name.
# EXAMPLES
The following examples assume the default option USE_44KHZ=ON, which means an output sample rate = 44100 Hz.
Example 1: Render a MIDI file and save the rendered audio as a raw audio file:
$ sonivoxrender ants.mid > ants.pcm
Example 2: pipe the rendered audio thru the Linux ALSA **aplay** utility:
$ sonivoxrender ants.mid | aplay -c 2 -f S16_LE -r 44100
is equivalent to:
$ sonivoxrender ants.mid | aplay -f cd
Example 3: pipe the rendered audio thru the **lame** utility creating a MP3 file:
$ sonivoxrender ants.mid | lame -r -s 44100 - ants.mp3
Example 4: pipe the rendered audio thru the **sox** utility creating a WAV file:
$ sonivoxrender ants.mid | sox -t s16 -c 2 -r 44100 - ants.wav
Example 5: pipe the rendered audio thru the PulseAudio's **pacat** utility:
$ sonivoxrender ants.mid | pacat
Example 6: pipe the rendered audio thru the PipeWire's **pw-play** utility:
$ sonivoxrender ants.mid | pw-play --rate 44100 -
Example 7: pipe the rendered audio thru the FFmpeg's **ffplay** utility:
$ sonivoxrender ants.mid | ffplay -i - -f s16le -ar 44.1k -ac 2 -nodisp -autoexit -loglevel quiet
Example 8: pipe the rendered audio thru the **mpv** media player:
$ sonivoxrender ants.mid | mpv --demuxer=rawaudio -demuxer-rawaudio-format=s16le --demuxer-rawaudio-rate=44100 --demuxer-rawaudio-channels=2 --no-video -
# BUGS
See Tickets at GitHub <https://github.com/EmbeddedSynth/sonivox/issues/>
# LICENSE AND COPYRIGHT
Licensed under the Apache License, Version 2.0
Copyright (c) 2022-2026 Pedro López-Cabanillas and contributors
|