.MOD
Amiga ProTracker module
Introduction
A MOD file is a song for a tracker, the music programs of the Commodore Amiga. It carries its own short 8-bit samples and a set of patterns: grids of rows that say which sample to play on each of four channels, at what pitch, with what effect. The format began with Ultimate Soundtracker and became standard through ProTracker.
MOD files are compact and sound the same everywhere, which made them popular in games, demos and the early internet music scene. Many later trackers extended the format to more channels.
Software
- OpenMPT (Windows)
- ProTracker 2 clone (Windows, macOS, Linux)
- XMPlay (Windows)
- VLC media player (Windows, macOS, Linux, mobile)
Structure
A MOD file starts with a 20-byte song title and 31 sample headers of 30 bytes each.
A sample header holds a 22-byte name, the length in 16-bit words, a finetune value, a
volume and the loop start and length. Then come the song length, a restart byte and a
128-byte order table listing which pattern plays at each position. At offset 1080 a
four-byte tag such as M.K. marks a 31-sample, 4-channel module. Other tags
such as 6CHN and 8CHN give more channels, and the oldest
15-sample files have no tag at all.
The patterns follow. Each has 64 rows of 4 channels, and each cell is 4 bytes holding the sample number, a 12-bit Amiga period (the pitch) and an effect with its parameter, so a 4-channel pattern is 1024 bytes. The number of patterns is one more than the highest number in the order table. The sample data comes last, as signed 8-bit values. All numbers are big-endian.
0Title song name20 bytes20Sample headers 31 of 30 bytes930 bytes950Song length, restart, order table130 bytes1080Tag M.K. and others4 bytes1084Patterns 64 rows × 4 channels × 4 bytes1024 bytes each…Sample data signed 8-bit, in sample ordervaries