Creating MIDI Instrument Definition Files with IDFEdit

Mark McCulley
Microsoft Corporation

October 6, 1997

Click to copy the IDFEdit sample file associated with this technical article.

Introduction

Do you love Microsoft® Windows® 95 but miss the MIDI Mapper Control Panel applet in Windows 3.1? Are you the type of person who has 17 different synthesizers and drum machines connected to your PC? If so, then you'll be interested in IDFEdit, a utility that allows you to create and edit MIDI Instrument Definition Files (IDFs). In this article I'll give you a general overview of the MIDI Mapper and the IDFEdit utility, which is the Windows 95 counterpart to the MIDI Mapper Control Panel applet in Windows 3.1. I assume you're familiar with using MIDI and with the MIDI Mapper, but not necessarily with programming MIDI applications.

About the MIDI Mapper

The MIDI Mapper translates and routes MIDI messages according to a user-defined configuration file. Why would you want to translate or route MIDI messages? Well, maybe you want to play General MIDI (GM) files on a non-GM synthesizer. Or maybe you want to route your percussion tracks to be played by an external drum machine instead of your sound card.

Windows 3.1 includes a Control Panel applet (aptly named MIDI Mapper) to allow users to configure the MIDI Mapper. Windows 95 does not include any utilities or Control Panel applets to configure the MIDI Mapper, because these days all new sound cards are GM-compatible and the average user doesn't really need to configure (in other words, screw up) the MIDI Mapper.

Instrument Definition Files

The MIDI Mapper uses IDFs to specify how MIDI events are routed and translated. (I think using the term instrument here is a bit confusing because there are other uses of this term in the MIDI realm—with IDFs, an instrument is actually a MIDI Mapper configuration.) A single IDF can contain one or more instruments. Each IDF instrument contains the following information:

The following illustration should give you an idea of the architecture of an IDF and a single IDF instrument:

Figure 1. IDF architecture

The IDF instrument shown above is very simple. Every channel except for channel 10, the drum channel, is muted.

About the IDFEdit Utility

To install an IDF created with IDFEdit, simply move the IDF file to the Windows\Config directory and run the Multimedia Control Panel applet. I'm not going to explain how to use IDFEdit in this article, but if you're familiar with the MIDI Mapper, you'll have no trouble getting up to speed.

The source code for IDFEdit is included in the Microsoft Platform SDK.