FFMPEG Basic Library Programming Development Learning notes-common audio format and subtitle format

Source: Internet
Author: User

statement: These articles about ffmpeg are only used to record my learning process and for later review, some of the text in the article may be directly from other articles, books or literature, learning ffmpeg related knowledge is to use on Android, I was just beginning to contact learning, Please also indicate if there is any mistake.
Audio format is to play in the computer or processing audio files, that is, to the sound file for the number, mode conversion, the process is also composed of sampling and quantization. The sound the ear can hear, the lowest frequency is from 20HZ to the highest frequency 20khz,20khz above the ear is not audible, so the maximum bandwidth of the audio file format is 20KHz, so the sampling rate needs to be between 40~50khz, and for each sample needs more quantization bits. The standard for audio digitization is the signal-to-noise ratio of 16-bit -96db per sample, which uses a linear pulse-coded modulation PCM with equal lengths for each quantization step. In the production of audio files, it is the adoption of this standard. Common audio formats are: CD format, WAVE (*. WAV), AIFF, AU, MP3, MIDI, WMA, RealAudio, VQF, Oggvorbis, AAC, APE. 1, CD format CD format sound quality is a relatively high audio format. So to speak the audio format, CD is naturally the leading pioneer. In most of the playback software "open file Type", you can see the *.CDA format, this is the CD track. The standard CD format, also known as the 44.1K sampling frequency, is the rate 88k/s,16 bit quantization, because the CD track can be said to be approximately lossless, so its sound is essentially faithful to the soundtrack. A CD audio file is a *.CDA file, which is just an index information, not really contains the sound information, so regardless of the length of the CD music, on the computer to see the "*.CDA" file is 44 bytes long. Note: You cannot directly copy the CD format *.CDA file to the hard disk playback, you need to use a track software like the EAC to convert the CD format files to WAV, this conversion process if the optical drive quality clearance and the EAC parameters are set properly, it can be said that basically lossless capture audio. 2, WAVEWAVE (*. WAV) is a sound file format developed by Microsoft, the standard format of WAV files and CD format, is also the 44.1K sampling frequency, the rate of 88k/s,16 bit quantization bit. Almost all audio editing software "knows" the WAV format. 3, Aiffaiff (Audio Interchange File format) format and AU format, they are very similar to WAV, in most of the audio editing software also support these common music formats. 4. auaudio file is a digital audio format introduced by Sun Company. The AU file was originally a digital sound file under the UNIX operating system. Because the Web servers on the Internet were primarily Unix-based, the files in AU format were also commonly used in sound file formats in today's Internet. 5, Mpegmpeg is the English abbreviation of the dynamic Image Expert group. MPEG audio files are referred to asThe sound portion of the MPEG standard is the MPEG audio layer. MPEG contains formats including: MPEG-1, MPEG-2, Mpeg-layer3, MPEG-4. 6, Midimidi (musical Instrument digital Interface) musical instrument number interface, is the the early 1980s to solve the problem of communication between electro-acoustic instruments proposed. MIDI is the most extensive music standard format in the arranger world, which can be called "computer-readable score". It uses the digital signal of the note to record music. A complete MIDI music is only dozens of KB large and can contain dozens of music tracks. Almost all modern music is crafted using MIDI plus a sound library. MIDI transmission is not a sound signal, but a note, control parameters and other instructions, it indicates what the MIDI device to do, how to do, such as playing which note, how much volume and so on. They are uniformly represented as MIDI messages (MIDI message). Asynchronous serial communication is used in the transmission, and the standard communication baud rate is 31.25* (1+/-0.01) KBaud. MIDI is a digital instrument interface that can be interpreted as a protocol, a standard, or a technique, but it does not refer to a single hardware device. MIDI system is actually a composing, orchestration, electronic simulation of the performance system. The data that is transferred from one MIDI device to another MIDI device is a MIDI message. MIDI data is not a digital audio waveform, but a music code or electronic score. MIDI is a unified communication protocol between electronic musical instruments and between electronic musical instruments and computers. When playing, according to the MIDI file recorded music information to the wave table issued instructions, from the "table" to find the corresponding sound information, after the synthesis, processing and playback. Because it uses a real instrument sample, the effect is naturally better than FM. The general Wave Meter's instrument sound information is recorded in 44.1KHz, 16Bit accuracy, in order to achieve the most realistic playback effect. 7. The wmawma (Windows Media Audio) format is a heavyweight player from Microsoft, with a strong background and stronger sound than the MP3 format, much more than the RA format, which is the same as the VQF format developed by Yamaha Corporation in Japan. is to reduce the data flow but to maintain the sound quality method to achieve higher than the MP3 compression rate, the compression rate of WMA can generally reach around 1:18. In addition WMA supports audio streaming (stream) technology for online playback on the network. 8, Realaudiorealaudio mainly applies to online music appreciation on the network, now most users are still using 56Kbps or lower rate of modem, so the typical playback is not the best audio. Some download sites will prompt you to choose the best real file based on your modem rate. Real's filesThere are several main formats: RA (RealAudio), RM (Realmedia,realaudio G2), RMX (RealAudio Secured), and more. These formats are characterized by varying the quality of the sound depending on the bandwidth of the network, making it easier for the most affluent listeners to get better sound when most people hear a smooth sound. 9, VQF Yamaha company Another format is *.VQF, its core is to reduce data flow but to maintain the sound quality method to achieve a higher compression ratio, VQF audio compression rate than the standard MPEG audio compression rate is nearly a fold, can reach about 18:1 or even higher. 10, Oggvorbisoggvorbis is a new audio compression format, similar to the MP3 and other existing music formats. But a little different is that it is completely free, open and without patent restrictions. Vorbis uses lossy compression, but by using more advanced acoustic models to reduce losses, the same bit rate coded ogg is better than MP3. And the MP3 format is protected by patents. 11, AMRAMR full name Adaptive multi-rate, Adaptive multi-rate encoding, mainly used for mobile audio, compression ratio is larger, but compared to other compression format quality is poor, because more for vocal, call, the effect is very good.


External subtitles and embedded captions of the description of the external subtitles: is the video file and subtitle file separation, when playing to import subtitle files. The advantage of external subtitles is that you can import your country's language. Embedded subtitles: Video files and subtitle files have been integrated, there is no way to change and remove. Three different formats for external subtitles:
1, SRT format: This is the best, small volume, with Notepad can open the editor. 2, Sub+idx: This is a graphic caption, can only be converted software with subtitles, large volume. 3, the title: Online less, more special effects than SRT. External subtitles Some basic notes: When using external subtitles, to ensure that the subtitle files and video files are placed in the same folder, and to ensure that the same file name, but do not modify the suffix and identification (common logo has CHS, GB, CHT, Big5, eng five kinds, where CHS and GB represent Simplified Chinese, cht and Big5 for Traditional Chinese, Eng for English) reprint please specify the Source: http://blog.csdn.net/android_jiangjun/article/details/46740237

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

FFMPEG Basic Library Programming Development Learning notes-common audio format and subtitle format

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.