Miles Sound System SDK 7.2a

AIL_install_MDI_INI

The function AIL_install_MDI_INI installs and initializes the currently selected MSS .MDI driver file for XMIDI music performance under DOS.

S32 AIL_install_MDI_INI(
  HMDIDRIVER *mdi
);

Out Parameters

mdi
points to an application variable of type HMDIDRIVER. If successful, AIL_install_MDI_INI will validate the application's HMDIDRIVER variable for use in subsequent function calls involving the driver. Otherwise, if an error occurs, *mdi's value will be undefined.

Returns

Returns one of the MILES_INSTALL_STATUS constants.

Discussion

For compatibility with other Miles platforms, you should use the AIL_open_XMIDI_driver function instead of this DOS-only function.

The SETSOUND Audio Configuration Utility program is provided as an extensible, device-independent installation and configuration program for MSS drivers. SETSOUND presents a list of all MSS drivers in the current working directory to the end user, allowing any desired driver to be selected and configured for use with an MSS application. The MSS example programs use AIL_install_MDI_INI and AIL_install_DIG_INI to load and initialize XMIDI and digital audio drivers in a single, easy step, eliminating the need to specify driver names on the DOS command line and ensuring compatibility with all end-user I/O configurations.

RAD Game Tools strongly recommends use of the SETSOUND utility to create DIG.INI and MDI.INI files describing the user's driver choices and configurations. MSS applications may then use the AIL_install_DIG_INI and AIL_install_MDI_INI functions instead of calling AIL_install_DIG_driver_file or AIL_install_MDI_driver_file directly.

You can use the NULL MIDI driver ("NULL.MDI") to load a "no-hardware" MIDI driver - this is commonly used when playing back DLS-only MIDI files.

This function calls AIL_read_INI to load the current MDI.INI file, and passes the parameters from the MDI.INI file to AIL_install_MDI_driver_file. Refer to the descriptions of these functions for a detailed summary of AIL_install_MDI_INI 's operation.

A return value of AIL_NO_INI_FILE generally arises from failure to run SETSOUND prior to launching the application. It does not indicate failure to detect sound hardware or problems related to driver initialization. These conditions are indicated by a return value of AIL_INIT_FAILURE.

You can use the AIL_set_redist_directory function to specify an alternate path to load the .MDI driver from (if the load fails from the current directory).


Group: XMIDI Services
Related Sections: SETSOUND - MSS Sound Configuration Utility
Related Functions: AIL_close_XMIDI_driver, AIL_install_DIG_INI, AIL_install_DIG_driver_file, AIL_install_MDI_INI, AIL_install_MDI_driver_file, AIL_open_XMIDI_driver, AIL_read_INI, AIL_set_redist_directory
Related Basic Types: HMDIDRIVER, MILES_INSTALL_STATUS, S32

For technical support, e-mail Miles3@radgametools.com
© Copyright 1991-2007 RAD Game Tools, Inc. All Rights Reserved.