Downloadable Sounds:
Down and Out in Cyberspace

by Neil Leonard
www.neilleonard.com

published in Electronic Musician, December 1998


Imagine that there was a standard wavetable instrument file format that was adopted by all software synthesizers, sound cards and even some hardware synthesizers. In short, the format was as widely supported as the standard MIDI file format. Also, suppose that when you ported sounds from synthesizer to another using this format, the instruments sounded virtually the same, because the synthesizer manufacturers had worked together to define a base level synthesis engine.

People using different platforms would have a common listening experience, even when listening to unique patches. Composers could transfer their core library of sounds between desktop synthesizers, samplers, synthesizers and dedicated game hardware without effort. They could later enhance the sound using a synthesizer's non-standard features. Creators of waveform and patch editors could support wide variety of software synthesizers, without writing unique import/export functions for each, and thus spend their time on application design.

Well, such a specification for synthesis and instrument storage now exists. It is called Downloadable Sounds (DLS) Level 1 specification. It was published in late 1997 by the MIDI Manufacturers Association and developed by members of its Interactive Audio Special Interest Group that includes engineers from IBM, Microsoft, S3, NVIDIA, ESS, Crystal Semiconductor, Yamaha, Sequoia Development, Sonic Foundry and Creative Labs.

This standard is so new that we are only now beginning to see its first usage in entertainment products. However, the idea makes so much sense and it has already been adapted by Microsoft and Apple as a cornerstone for their software synthesizers. People we spoke to at the aforementioned companies said that they expect DLS will be adopted as an industry-wide standard, and that MIDI will blossom as a premiere approach for quality interactive music on desktop systems.

How it works

In order to insure the acceptance of DLS, the MMA first defined bare bones synthesizer for immediate implementation on the widest range of systems. The synthesis architecture is comprised of three distinct sub-systems: control logic, a digital audio engine and articulation modules and routings.

The control logic receives incoming messages and determines which MIDI channel, sample and articulation module to use. Level 1 instruments are limited to multi-sampled keymaps with no velocity switching or layering.

The digital audio engine is comprised of a digital oscillator and a digitally controlled amplifier. Unlike hardware synthesizers, the oscillator accepts both 16 and 8-bit samples. A wide range of sample rates are supported for wavetables. However, DLS synthesizers must support a minimum sample rate is 22,050 Hz. Up to one sample loop is supported.

The oscillator can modulate the pitch in accordance with input from an LFO, envelope generator or a MIDI pitch bend event. The amplifier responds to input from an LFO, envelope generator or MIDI volume event. The MMA made a clear attempt to support dynamically responsive real-time expression that gives MIDI an edge over basic digital audio playback.

The Level 1 audio path simply routes the signal from the oscillator to the amplifier to the digital-to-analog converter (DAC). Future additions to DLS will allow for additional processing modules located between the oscillator and the DAC.

An articulation module is a set of devices that increase expressive control over the sample as it plays. The Level 1 specification uses LFOs, envelope generators and external MIDI events in a preset routing arrangement. Later specifications will support this routing as one configuration in a flexible system with many other possible combinations.

The MMA specification emphasizes that the modulation routing is "purely a symbolic system that can be mapped on many different hardware designs." It is not intended to propagate an homogenous real-time architecture, but rather a "common language between different hardware implementations."

There are two types of DLS instruments, melodic instruments and drum kits. Both types consist of a collection of wavetables and associated synthesis parameters. Melodic instruments can be accessed by any MIDI channel except 10, which is reserved for drum kits.

DLS instruments include a default bank and instrument number. DLS synthesizers can download instruments to any bank and program location. To avoid conflict with GM, GS and XG synthesizers, which allocate sounds for specific locations, DLS synthesizers must first be sent a system exclusive message to enable this feature. Each DLS compliant synthesizer has a unique device ID.

DLS also defines a set of parameters termed a "region" that includes MIDI note and velocity ranges, articulation information and the location of the wavetable data. A melodic instrument can have up to sixteen regions. Drum kits can have up to 128 articulation modules.

One early proposal for the file format was Creative Labs' SoundFonts format. However, the consensus at MMA was for a non-proprietary format, like the Standard MIDI File format. The actual DLS file format is unique but borrows its overall structure from Microsoft's Resource Interchange File Format (RIFF). RIFF files are a bit like AIFF files in that the date is organized into discrete groupings called "chunks," which in turn can contain sub-chunks. Wavetable data is stored in the WAVE file format and embedded in the RIFF file.

DLS Tools

I went in search of a way to create original DLS instruments and use them in a sequence. I found four editors to create sounds, all available for Windows only. Reportedly, E-mu will shortly have a version of their Vienna editor which saves a DLS file.

SynthAuthor, which is distributed by the MMA was used by Roland to create the DLS Sound Canvas library that ships with Microsoft DirectMusic [Fig. 1]. This same library was later loaded to Apple's Atomic Editor, which imports DLS instruments, and converted to QuickTime musical instruments to provide QuickTime's first full GM library.

FM Software's Awave lets you edit wavetable instruments and converts between more than one hundred audio carrying file formats, including SoundFonts and Mod Files [Fig. 2]. It can batch process files, has a graphic editor for setting loop-points, supports re-sampling, fades, normalization, effects and even has a real-time oscilloscope and spectrum analyzer graph. The instrument editor provides full support for all of the features of DLS.

Rad Gametools bundles a DLS editor and a DLS synthesizer with its Miles Sound System (MSS). MSS is a comprehensive collection of MIDI and audio drivers for Windows and DOS machines that can be programmed in the C programming language. MSS includes an Xtra file for Macromedia Director that allows you to play MIDI sequences using the Lingo scripting language.

According to Tom White, President of MMA, "To use DLS files in a sequence is harder, since current sequencers do not handle the downloading for you. Most sequencers will look to the OS to provide a mechanism which they can call ... much like calling MIDI or audio port drivers. MS is providing this in DirectMusic, and Apple will do so in QT3 (which currently requires conversion of DLS to QTMI). Until all this happens, some titles may use the S3 API, or the download may be done by the user on those cards which provide a utility."

DirectMusic

At present the best way to try out DLS is in Microsoft's DirectX Software Developers Kit. It is shipped on CD for $12.50 and available for free via the Internet for a limited time. As the entire package is over 60 megabytes, the CD route seems more sensible for most. The DirectX kit includes DirectMusic Producer (DMP), which has a DLS editor, DLS based sequencer and extensive interactive composition tools [Fig 3 & 4]. While still in its Beta stage, DMP performed reliably and its DLS editor was more intuitive than the MMA's SynthAuthor.

DMP allows composers to embed compositional techniques in a non-linear music presentation. Composers can import standard MIDI files that contain musical fragments, specify guidelines for variations and DirectMusic music will generate unique variations on the material every time it is called for. Styles can be changed on the fly, and it can notify the calling application when it has finished a musical transition, making it an ideal tool for interactive presentations.

DMP is the next wave of music multimedia on the Windows platforms and DLS is the core synthesis technology. All sounds are synthesized in software using DLS instruments, then output using the sound card's DAC. General MIDI sounds can be played using DLS's Sound Canvas library, or by using external GM sounds on a card or an external synthesizer.

One of the key people in the development of the DLS specification was Todor Fay, Development Lead, for DirectMusic and co-chair of the MMA's IASIG for DLS. Fay worked on SynthAuthor and later DirectMusic Producer. He said that sound cards as we know them to are likely to disappear and be replaced with DLS accelerators. The accelerators will have no onboard sounds but will provide higher sound quality than the software synth, because hardware synths aren't constrained by CPU cycles. For example, they can run at higher rates, use multi-point interpolation, and support multiple levels of DLS.

The Level 1 specification has actually be on the table for over two years and the Microsoft DLS engine, which was initially written by Fay is about that old. It is the first DLS software synthesizer and has already been highly optimized. According to Fay, "on a Pentium 120 it uses 1% of the CPU's clock cycles per voice. On a Pentium 166 with MMX it uses .3%. On a Pentium II 266 it uses .12%. When used for MIDI playback it offers jitter free performance."

The synthesizer was used in Microsoft's Interactive Music Architecture(IMA) and was often heard in Microsoft Network presentations. IMA is being used in forthcoming games by Monolith. There's an ActiveX Web control that you can get from www.microsoft.com/music/. The site lets you download the development kit and also has pointers to public domain web sites that use it. It lets you put interactive music on your web pages.

Down the road

A forthcoming Level 2 specification will address more advanced features that will match the next generation of wavetable synthesizers. As this article was written, Level 2 of the specification was already in the works. The MMA actually hopes that the timely release of the Level 2 spec. will actually help define present synthesizer chip design. The standard does not preclude latter inclusion of steaming audio and real-time downloads.

According to Tom Savell of the Joint E-mu/Creative Technology Center, "the DLS Level 2 Specification has not been ratified by the MMA as it is still a work in process. DLS-2 has the potential to be a very far reaching standard as it is also to become part of the MPEG-4 specification. In fact, it is MPEG-4 that is driving our schedule to complete because they must have the MMA specification sometime in the next month in order to incorporate it into their specification.

"Initially, MPEG was considering SoundFonts(tm) 2.0 as the method of describing wavetable (sampled audio) patches. Then, the MMA suggested that DLS would have wider industry acceptance since SoundFonts(tm) 2.0 was a proprietary standard belonging to E-mu. However, MPEG was very far along in their process and had essentially accepted SoundFonts(tm) 2.0. Additionally, DLS Level 1 lacked many important features of SoundFonts(tm) 2.0 such as second order resonant low pass filters, overlapping key and velocity ranges, and 6-stage envelopes. So, MPEG agreed in concept to adopting DLS, but only if it included all the features of SoundFonts(tm) 2.0 and was completed in time."

SIDEBAR - GENERAL MIDI

Sound compatibility has been a long standing problem in interactive presentations. On the Windows platform alone there are a number of sound cards, and each one uses a different synthesis engine and instrument library.

The acceptance of General MIDI helped narrow the problem by providing a standard instruments mappings. However, each GM synthesizer can use different sampled wavetables, synthesis architectures, and audio circuitry. As a result, any given GM instruments can vary greatly when played by different synthesizers. As a result some leading game composers often make several versions of their music optimized for different synthesis engines. Others opt for digital audio playback to insure sonic uniformity.

The DLS specification provides a solution to this problem by providing a means of delivering unique instruments across a wide variety of synthesizers, without compromising the common listening experience.

CONTACT SHEET

MIDI Manufacturers Association
www.midi.org

FM Software, Awave editor
http://hem.passagen.se/fmj/fmjsoft.html

[Fig. 1] The SynthAuthor interface displays available instruments in a library, waveform and articulation data. The foremost window is for editing articulation data.

[Fig. 2] Awave's loop point editor.

[Fig. 3] DirectMusic Producer's interface with the DLS instrument editor open to its Volume edit screen.

[Fig. 4] DirectMusic Producer's interface with the DLS instrument editor open to its LFO edit screen.

Neil Leonard III received this year's award for the most valuable contribution to the Music Technology Division curriculum at Berklee College of Music. He has performed his original works for saxophone and interactive systems throughout North America, Latin America and Europe.