Introduction
MP1 is Layer I of the MPEG-1 audio standard (ISO/IEC 11172-3), the simplest of the three layers. It splits the sound into 32 subbands, gives each subband a number of bits and a scale, and stores 12 samples of each subband in every frame. It has no scalefactor sharing, no grouped samples and no entropy coding, so its bit rates are high (up to 448 kilobits a second) and it is the cheapest of the layers to decode.
Structure
An MP1 file is a run of independent frames. Each frame starts with a 4-byte header: a 12-bit sync word of ones, the version bit, the layer (Layer I), a protection flag, the bit rate, the sample rate, a padding flag and the channel mode. An optional CRC follows, then the bit allocation, the scalefactors and the quantised samples. A Layer I frame holds 384 samples for each channel and takes a whole number of 4-byte slots. Files may also carry ID3 tags.
0Frame repeated to the end of the filevaries+0Header sync, version, layer, bit rate, sample rate, mode4 bytes+4CRC optional2 bytes…Bit allocation 32 subbands, 4 bits each16 to 32 bytes…Scalefactors 6 bits for each subband in usevaries…Samples 12 slots of one value for each subband in usevaries…Ancillary data whatever remains in the framevaries
The same frame layout also covers MPEG-2’s lower sample rates (22,050, 24,000 and 16,000 Hz; ISO/IEC 13818-3). The reference pages give every field and table:
- Frame header – every field and code, the bit rates, the sample rates, the frame length and the CRC
- Audio data – bit allocation, scalefactors, the sample codes, joint stereo and ancillary data
- Decoding – turning the codes into sound: requantisation and the 32-band synthesis filter
Layer II files (MP2) share the header and the synthesis filter, and differ in their allocation tables, scalefactor selection and grouped samples. Tags in MP1 files are the same as in MP3: see ID3v2 and ID3v1.
The layer is stored in every frame header (layer), not in the file name, so Layer I frames also turn up in files named .mp2 or .mp3. The explorer opens them by their headers.
Links
Software
- VLC media player – free player for almost any audio or video file (Windows, macOS, Linux, mobile)
- foobar2000 – free music player and converter (Windows, macOS, mobile)
- FFmpeg – command-line tool that decodes MP1 (Windows, macOS, Linux)
- mpg123 – command-line player for MPEG Layers I, II and III (Windows, macOS, Linux)
Developers
- libmpg123 – decoder for MPEG Layers I, II and III (C)
- iso-dist10 – the ISO reference encoder and decoder source (C)
Reference
- ISO/IEC CD 11172-3 – the committee draft of MPEG-1 audio, which defines Layers I, II and III
- ISO/IEC 11172-3:1993 – the published MPEG-1 audio standard (paid)
- ISO/IEC 13818-3 – MPEG-2 audio, adding the lower sample rates (paid)