MIDI files

?

MIDI Files Introduction

What is a MIDI file?

A Musical Instrument Digital Interface (MIDI) file is an instructional file which explains how the sound should be produced after a device or a piece of software has been loaded to play the sound without producing the actual sound itself

What does a MIDI file contain?

MIDI data contains a list of events or messages that tell an electronic device (such as a mobile phone or a musical instrument) how to generate certain sounds.

What can MIDI files be used with?

MIDI files are used with musical instruments such as keyboards or alternatively any electronic device which contains synthesizer software such as mobile phones, computers with sound cards and karaoke machines.

1 of 3

MIDI File Structure

  • A standard MIDI file is composed of "chunks". It starts with a header chunk and is followed by one or more track chunks.The header chunk contains data about the file and the track chunks contain a logical track.

A chunk always has three components:

  • The track ID string (always 4 characters long)
  • Then a four bit unsigned value specifying the nuber of bytes in the data section
  • Fianlly, the data section of the chunk

Header Chunk

  • The header chunk consists of a literal string denoting the header, a length indicator, the format of the MIDI file, the number of tracks in the file and a timing value specifying delta time units.

Track Chunk

  • A track chunk consists of a literal indentifier string, a length indicator specifying the track size and actual event data making up the track
2 of 3

MIDI File Messages

Some examples of MIDI messages are:

  • Note On which signifies that a key has been pressed or a note on an instrument has been played (includes what key and the velocity)
  • Note Off which signifies that a key has been released or a note has stopped being played.
  • Polyphonic Key Pressure which is a measurement of how hard the button is pressed once it has reached the bottom
  • Control Change which indicates that a controller has been connected (e.g. a foot pedal). This message includes the number assigned to the controller (0 - 127)
3 of 3

Comments

No comments have yet been made

Similar Computing resources:

See all Computing resources »See all MIDI Files resources »