Structure of an mp3


Free Download Mp4Gain
picture

Structure of an mp3

 

Structure of an mp3
Structure of an mp3

audio compression

Structure of an mp3
Structure of an mp3

 

The MP3 format began in the mid-1980s and the Fraunhofer Institute in Erlangen, Germany, was committed to high-quality, low-data-rate audio coding.

MP3 audio compression includes encoding and decoding in two parts. Encoding is converting the data in the WAV file into a highly compressed bitstream format, and decoding is accepting the bitstream and reconstructing it into the WAV file.

MP3 uses the distortion algorithm of Perceptual Audio Coding (PerceptualAudioCoding). The frequency range of sound perceived by the human ear is from 20 Hz to 220 kHz. MP3 cuts out a lot of redundant signals and irrelevant signals. The encoder transforms the original sound into the frequency domain through a hybrid filter bank. Using the psychoacoustic model, it is estimated that it may simply be The perceived noise level is quantized and converted to Huffman coding to form an MP3 bitstream. The decoder is much simpler and its task is to extract the sound signal from the encoded spectral line components through inverse quantization and inverse transformation.

When compressing audio data, the original sound data is first divided into fixed blocks, and then direct MDCT is performed. MDCT itself does not perform data compression, but only converts a set of time-domain data to frequency-domain data to obtain time-domain data. In case of change, the direct MDCT converts the value of each block into 512 MDCT coefficients. Quantization compresses data, and when bits are allocated to transformed samples after quantization, it is necessary to consider making the entire quantized block the smallest, which becomes lossy compression. When decompressing, the 512 coefficients are restored to the original sound data by reverse MDCT, and the original sound data before and after are inconsistent, because redundant and irrelevant data are removed during the compression process.

 

MP3 file structure
MP3 files are roughly divided into three parts: TAG_V2(ID3V2), Frame, TAG_V1(ID3V1)

ID3V2 Contains information such as author, composer, album, etc., the duration is not fixed, expanding the amount of information of ID3V1
framework

 

 

 

A series of frames, the number is determined by the file size and frame length

The length of each frame can be variable or fixed, determined by the bit rate.

Each FRAME is divided into two parts: frame header and data entity

The frame header records the bitrate, sample rate, version, and other mp3 information, and each frame is independent of each other.

ID3V1    Contains author, composer, album and other information, length is 128BYTE


Free Download Mp4Gain
picture


Mp4Gain Main Window
picture


Mp4Gain Features
picture


Free Download Mp4Gain
picture

Structure of an mp3

Structure of an mp3

 

Structure of an mp3
Structure of an mp3

The full name of MP3 is MPEG Audio Layer3, which is an efficient computer audio coding scheme.

Structure of an mp3
Structure of an mp3

It converts audio files into smaller files with .MP3 extension with a higher compression ratio and basically keeps the sound quality of the original file. MP3 is part of the ISO/MPEG standard. The ISO/MPEG standard describes audio compression using a high-performance perceptual coding scheme. This standard has been continuously updated to meet the pursuit of “high quality, low volume”. MPEGLayer1, Layer2 , and Layer 3 have now formed three audio codec schemes. The compression rate of MPEGLayer3 can reach from 1:10 to 1:12. A 1M MP3 file can play for 1 minute, while a 1 minute CD-quality WAV file (44100 Hz, 16-bit, two channels, 60 seconds) will take up 10M of space. , A 650M MP3 disc should play for more than 10 hours, while a CD with the same capacity should play for about 70 minutes. The advantages of MP3 are unmatched by CD.

MPEG audio standard
MPEG (Motion Picture Experts Group) is a moving picture expert group under ISO, and the MPEG standard it creates is widely used in various multimedia. MPEG standards include video and audio standards, among which MPEG-1, MPEG-2, MPEG-2AAC, and MPEG-4 audio standards have been developed.

The MPEG-1 and MPEG-2 standards use the same family of audio codecs: Layer 1, 2, and 3. A new feature of MPEG-2 is the use of low sample rate expansion to reduce data traffic, and another feature is multi-channel expansion, which increases the number of main channels to five. The MPEG-2AAC (MPEG-2 Advanced Audio Coding) standard was released by FraunhoferIIS and AT&T in 1997, with the goal of significantly reducing data traffic. MPEG22AAC adopts the Modified Discrete Cosine Transform (MDCT) algorithm and the sampling rate can be between 8 KHz and 96 KHz. The number of channels can be between 1 and 48.

MPEG Audio Layer1, 2, and 3 use the same filter bank, bitstream structure, and header information, and the sample rate is either 32 KHz, 4411 KHz, or 48 KHz. Layer1 is designed for DCC (DigitalCompactCassette) digital compression tape, the data rate is 384kbps, Layer2 has made a compromise between complexity and performance, and the data rate has been reduced to 256kbps-192kbps. Layer 3 was designed for low data traffic from the start, and data traffic ranges from 128 kbps to 112 kbps. Layer 3 adds MDCT transform, making its frequency resolution 18 times higher than Layer 2. Layer 3 also uses EntropyCoding similar to MPEGVid2eo, reducing redundant information. The vast majority of MP3s use the MPEG21 standard.

What are MP3 files?

What are MP3 files?

What are MP3 files?

 

The audio format is directly related to the quality and purpose of the audio track, i.e. where and on which device it will be played and what is its purpose.

What are MP3 files?

But before you can figure out the difference between them and choose the best audio format for your music, you need to know what categories they fall into. Let’s keep going!

Uncompressed audio is like a picture, and uncompressed audio is of better quality, larger file size, safer to copy, and nearly identical in detail to the original sound.

WAV is the most widely used of these audio formats and plays music just as accurately as it records it.

compressed audio
When music is compressed, the files become smaller and can be easily stored on a device. Due to this advantage, users tend to choose compressed audio more.

However, it must be remembered that some audio formats in this category may lose quality depending on the option selected, just like MP3 and AAC.

What is the best audio format?
As we said before, the first step in deciding on an audio format is to know the final objective of the track. Whether it’s for music lessons, performances, karaoke, auditions, or recording versions, you need to understand the pros and cons of each option.

WAV
WAV (Waveform Audio File Format) is an uncompressed format and therefore requires ample storage space. This is suitable for those who already work with music, such as subject matter experts, or users who want to edit audio.

At high fidelity rates, WAV faithfully reproduces the elements and characteristics of the original soundtrack. Also, this format allows you to choose between different sample rates and bit rates and can be used on multiple platforms.

FLAC
FLAC (Free Lossless Audio Codec) is one of the most widely used compression formats by music lovers these days.

Digital audio encoding allows you to preserve its quality, but the resulting file will be smaller. Over the years, this format has become more widely used and compatible with different devices and platforms.

FLAC is free and open source, ready to use and can be easily played on smartphones and other devices.

MP3
Before deciding on the best audio format, it is worth taking a look at the most famous format in the world of music: MP3.

MP3 is one of the leading audio compression formats, and has become synonymous with the convenience and efficiency of producing files quickly, with smaller files, and at a certain level of quality.

Many devices and programs can play this format. But MP3 is difficult to use in professional audio processing and advanced audio editing.

As is known, this format exists on almost all platforms and is ideal for sharing audio.

Another interesting factor is its bitrate, although in a compressed format it can vary depending on the user’s objectives and quality improvements.

AAC Like MP3, Advanced Audio Coding (AAC) is a more efficient audio format than its predecessor.

If you need to create smaller files with less storage space, AAC is a great choice, reducing the file size for the user while maintaining a high-quality audio track.

Compatible with different platforms and devices, it is convenient to apply in different situations.

Analysis of the above audio formats leads to the conclusion that it is impossible to say which format is better than the other, just that each target has its own ideal format. So before downloading or uploading a file, check what platform the music will play on and what it is for.

What are MP3 files?

What are MP3 files?

What are MP3 files?
What are MP3 files?

A file with the .mp3 extension is a digitally encoded file format for audio files, officially based on MPEG-1 Audio Layer III or MPEG-2 Audio Layer III.

What are MP3 files?
What are MP3 files?

It was developed by the Moving Picture Experts Group (MPEG) using Layer 3 audio compression. The compression achieved by the MP3 file format is 1/10 the size of a .WAV or .AIF file. This format offers the advantage of streaming such audio files over the Internet for online listening, which was previously not possible due to the large size of audio files. The sound quality of MP3 audio files can be controlled by setting parameters such as bit rate, sample rate, common or normal stereo.

A brief history of MP3

The MP3 format was invented and developed by a German company, Fraunhofer-Gesellshart. The algorithm has licensed patents for the compression techniques it uses. Here’s a helpful MP3 schedule:

• 1987 : The Fraunhofer Institute in Germany begins research on high-quality, low-bitrate audio coding. It’s called the EUREKA project EU147, Digital Audio Broadcasting.

• January 1988: The Moving Picture Experts Group (MPEG) is formed.

• **April 1989**: Fraunhofer patented the MP3 in Germany.

• 1992-Dieter Seitzer, who helped Fraunhofer with his research, integrated his audio encoding with MPEG-1.

• 1993 – Publication of the MPEG-1 standard.

• 1994 – The MPEG-2 standard was developed and released a year later.

• November 26, 1996 : US patent for MP3 is published.

• September 1998 – Fraunhofer begins to enforce the patent. People who used the MP3 audio codec paid Fraunhofer a license fee.

• February 1999 – SubPop, a record label, releases music in MP3 format, the first to do so.

• 1999 – The first portable MP3 player appears.

File format MP3##
MP3 files consist of MP3 frames, where each frame consists of a header and a data block. Frames are not independent and generally cannot be mined at arbitrary frame boundaries. The data blocks of a file contain frequency and amplitude information about the audio. The sync word in the header identifies the start of a valid frame. This is followed by 3 bits where the first bit indicates that it is an MPEG standard and the remaining 2 bits indicate that layer 3 is used; therefore, MPEG-1 Audio Layer 3 or MP3. After this, the value will vary depending on the MP3 file. ISO/IEC 11172-3 defines the range of values for each part of the header and the header specification. Most current MP3 files contain ID3 metadata, which precedes or follows the MP3 frame, as shown. Data streams may contain an optional checksum.

MP3 File Structure Analysis Part 2

MP3 File Structure Analysis Part 2

mp3

Sounds in nature are very complex and waveforms are extremely complex.

Mp3

Usually we use pulse code modulation coding, that is, PCM coding. PCM converts continuously changing analog signals into digital codes through three steps of sampling, quantizing, and encoding.

u Decode:

Reverse encoding process

1.1.2 Brief introduction of MP3
The full name of MP3 is MPEG Audio Layer 3. It is an efficient computer audio coding scheme. It converts audio files into smaller files with a .mp3 extension with a higher compression ratio, essentially maintaining the sound quality of the source file. MP3 is part of the ISO/MPEG standard,

The ISO/MPEG standard describes audio compression using a high performance perceptual coding scheme. This standard has been continuously updated to meet the pursuit of “high quality and low quality”. Three audio codec schemes, MPEG Layer1, Layer2 and Layer3, have been formed, respectively, corresponding to the three sound files MP1, MP2 and MP3

MPEG (Moving Picture Experts Group) is a group of moving picture experts under ISO. The MPEG standard it specifies is widely used in various multimedia. The MPEG standard includes video and audio standards. Audio standards have developed MPEG-1, MPEG -2, MPEG-2 ACC, MPEG-4. The MPEG-1 and MPEG-2 standards use the same family of Layer1, 2, 3 audio codecs, and most MP3s use the MPEG1 standard.

MP3 audio compression consists of two parts: encoding and decoding. Encoding is the process of converting the original signal to a level signal, and decoding is the reverse process. MP3 uses the PerceptualAudio Coding distortion algorithm. The frequency range of sound perceived by the human ear is 20 Hz to 20 kHz. MP3 cuts out a lot of redundant signals and irrelevant signals. The encoder transforms the original sound into the frequency domain through a mixed filter bank and uses a psychoacoustic model. to estimate that it may be only The perceived noise level is quantized and converted to Huffman coding to form an MP3 bit stream. The decoder is much simpler, its task is to extract the sound signal from the encoded spectral line components through inverse quantization and inverse transformation.

MP3 file data consists of multiple frames, and a frame is the smallest unit of an MP3 file. Each frame, in turn, consists of a frame header, additional information, and sound data. The playback time of each frame is 0.026 seconds and its duration varies with the bit rate. Some MP3 files have extra bytes at the end that contain description information for non-audio data.

MP3 file structure analysis

MP3 file structure analysis

MP3 FORMAT

ü ID3:

mp3 format

 

Usually located in several bytes at the beginning or end of an mp3 file, it records the singer, title, album name, era, style, and other mp3 file information.

ID3 is divided into two versions, the V1 ID3 version is fixed at the end of the 128-word file section, it begins with the TAG character, if there is no ID3V1 information, it is considered that there is no ID3V1 information, the V2 ID3 version is found. at the beginning of mp3 and the length is variable.

ü Sampling rate:

The number of samples extracted from a continuous signal to form a discrete signal per second. It is expressed in Hertz (Hz). Sampling rate refers to the sampling frequency when converting an analog signal to a digital signal, i.e. how many points are sampled per unit of time. The higher the sample rate, the more realistic and natural the sound will be. On today’s major capture cards, the sample rate is generally divided into three levels: 22.05 KHz, 44.1 KHz, and 48 KHz. 22.05 KHz can only achieve the sound quality of FM radio, and 44.1 KHz is the theoretical limit of CD sound quality, and 48 KHz is more accurate.

ü Bit rate:

Bit rate refers to the number of bits (bits) transmitted per second. The unit is bps (bit per second). The higher the bit rate, the more information transmitted. In the audio and video fields, bit rate often translates to bit rate. The bit rate indicates how many bits per second the encoded (compressed) audio and video data should represent, and a bit is the smallest unit in binary. 0 or 1. The relationship between bitrate and audio and video compression is simply that the higher the bitrate, the better the quality of the audio and video, but the larger the encoded file; if the bitrate is lower, the situation is just the opposite.

Bit rate = sample rate * number of samples * number of channels

ü Bitrate/Stream/Bitrate:

It refers to the data stream used by audio and video files in a unit of time. The popular understanding is the sample rate, which is the most important part of quality control in audio and video encoding. Generally, the units we use are Kb/s and Mb/s. . Generally speaking, the higher the code stream, the lower the compression ratio and the higher the quality. The higher the code stream, the higher the sampling rate per unit time, the higher the data stream, the higher the accuracy, and the closer the processed file is to the original file.

ü Code:

From the point of view of information theory, the data that describes the source of information is the sum of the redundancy of information and data, namely: data = information + data redundancy. The audio signal has correlation in the time domain and the frequency domain, that is, there is data redundancy. Taking audio as the source, the essence of audio encoding is to reduce redundancy in the audio.