Media Control Interface

From Wikipedia, the free encyclopedia

The Media Control Interface, MCI in short, is an aging API for controlling multimedia peripherals connected to a Microsoft Windows or OS/2 computer. MCI makes it very simple to write a program which can play a wide variety of media files and even to record sound by just passing commands as strings. It uses relations described in Windows registries or in the [MCI] section of the file SYSTEM.INI.

The MCI interface is a high-level API developed by Microsoft and IBM for controlling multimedia devices, such as CD-ROM players and audio controllers.

The advantage is that MCI commands can be transmitted both from the programming language and from the scripting language (open script, lingo aso). For example mciSendCommand or mciSendString. For a number of years, the MCI interface has been phased out in favor of the DirectX APIs.


[edit] MCI Devices

The Media Control Interface consists of 4 parts:

- AVIVideo

- CDAudio

- Sequencer

- WaveAudio

Each of these so-called MCI devices can play a certain type of files e.g. AVIVideo plays avi files, CDAudio plays cd tracks ...

Also other MCI devices are available these days.


[edit] Playing media through the MCI interface

To play a type of media, it needs to be initialized correctly using MCI commands. These commands are subdivided into categories:

- System Commands

- Required Commands

- Basic Commands

- Extended Commands


A full list of MCI commands can be found at Microsoft's MSDN Library.

In other languages