A newer version of Max is available. Click here to access the latest documentation.

The DLS Synthesizer

Max uses the DLS synthesizer as its default MIDI output destination. You can send data directly from Max via MIDI to produce sound without using any external MIDI gear.

On the Macintosh, the default MIDI output is an AudioUnit DLS (Down-Loadable-Sounds) synthesizer. The AU DLS synth supports its own set of internal sounds as a General MIDI bank, and also provides support for Level 2 SoundFont files.

On Windows systems, the default MIDI output is the Microsoft DirectMusic DLS (Downloadable Soundfont) synthesizer (Note: the Microsoft DLS synthesizer does not support SoundFont files)

Only one port for the DLS synth is created by default. (augraph on Mac OS X or midi_dm (on Windows). However, you can work with more than one DLS synth by creating additional MIDI synthesizer ports and assigning new DLS sound bank files to each one.

Addressing the DLS synthesizers currently requires that you send messages to the Max application by typing a semicolon followed by a message text into a message box, then clicking on the message box.

Creating a new port for a DLS synth

  • In an unlocked Patcher window, type "m" to create a blank message box object with an active text cursor.
  • To create a new port, type

;#SM createoutport <portname> <drivername>

into the message box, replacing <drivername> with the name of the driver you want to use (midi_dm on Windows and augraph on the Macintosh) and <portname> with the name you want to give to your virtual output port. Note that the message starts with a semicolon.

  • Lock the patcher window, and click in the message box to send the message to Max.

For example, the clicking on the following message box in a Max patch will create a second DLS synth called “synth2” in a Macintosh system:

;#SM createoutport synth2 augraph

Clicking on the following message box in a Max patch will create a second DLS synth called “othersynth” on a Windows system:

;#SM createoutport othersynth midi_dm


Deleting a DLS synth port

  • In an unlocked Patcher window, type "m" to create a blank message box object with an active text cursor.

To delete a port, type

;#SM deleteoutport <portname> <drivername>

into the message box, replacing <drivername> with the name of the driver you want to use (midi_dm on Windows and augraph on the Macintosh) and <portname> with the name you want to delete. Note that the message starts with a semicolon.

  • Lock the patcher window, and click in the message box to send the message to Max.

For example, the clicking on the following message box in a Max patch will delete the DLS synth called “synth2” in a Macintosh system:

;#SM deleteoutport synth2 augraph

Clicking on the following message box in a Max patch will delete the DLS synth called “othersynth” on a Windows system:

;#SM deleteoutport othersynth midi_dm

You can load type 1 or 2 sound banks by sending messages to the Max application.


Loading a Bank of Sounds on a DLS Synth (type 1 or 2)

  • In an unlocked Patcher window, type "m" to create a blank message box object with an active text cursor.

To delete a new bank of sounds into a DLS synth, type

;#SM driver loadbank <filename> <portname>

into the message box, replacing <filename> is the name of an existing DLS bank file, and <portname> with the name of the port that will use this bank. If you omit the <portname> argument from the message box, the bank you specify fill be loaded by all DLS ports. On Macintosh systems, the folder /Library/Audio/Sounds/Banks is added to the search path when looking for a DLS bank file (i.e. it is the default location for searching for sound bank files).

Note that the message starts with a semicolon.

  • Lock the patcher window, and click in the message box to send the message to Max.

If you specify a zero (0) for the filename, the default GM (General MDI) sound bank will be loaded (e.g., ;#SM driver loadbank 0 <portname>)

You can turn reverb on or off (the default state) by sending messages to the Max application:


Turning Reverb On and Off

  • In an unlocked Patcher window, type "m" to create a blank message box object with an active text cursor.

To enable reverb, type

;#SM driver reverb 1 <portname>

To disable reverb, type

;#SM driver reverb 0 <portname>

into the message box, replacing <portname> with the name of the port.

Note that the message starts with a semicolon.

  • Lock the patcher window, and click in the message box to send the message to Max.

If you're running Max on a Windows system, you can set an output latency value for MIDI output.


Setting MIDI Output Latency (Windows systems only)

  • In an unlocked Patcher window, type "m" to create a blank message box object with an active text cursor.

To set MIDI output latency, type

;#SM driver latency <time> midi_dm

into the message box, replacing <time> with a time value in milliseconds.

Note that the message starts with a semicolon.

  • Lock the patcher window, and click in the message box to send the message to Max.

For example, the following message would set the latency to 10 milliseconds:

;#SM driver latency 10 portname

See Also

Name Description
Technical Notes Technical Notes