IOS audio development-'audiostreambasicdescription'

Source: Internet
Author: User

IOS audio development-'audiostreambasicdescription'

This class provides descriptions of audio files

 
 
  • An audio stream is a continuous series of data that represents a sound, such as a song.

  • A channel is a discrete track of monophonic audio. A monophonic stream has one channel; a stereo stream has two channels.

  • A sample is single numerical value for a single audio channel in an audio stream.

  • A frame is a collection of time-coincident samples. For instance, a linear PCM stereo sound file has two samples per frame, one for the left channel and one for the right channel.

  • A packet is a collection of one or more contiguous frames. A packet defines the smallest meaningful set of frames for a given audio data format, and is the smallest data unit for which time can be measured. In linear PCM audio, a packet holds a single frame. In compressed formats, it typically holds more; in some formats, the number of frames per packet varies.

  • The sample rate for a stream is the number of frames per second of uncompressed (or, for compressed formats, the equivalent in decompressed) audio.

First, audio files are generated by analog signals-> digital signals after PCM-> compressed and encoded audio files.
The sampling frequency of PCM is called sample rate.
Several sampling data can be obtained for each sampling, corresponding to multiple channels.
Several sampling data obtained from each sampling point are combined and called a frame.
The combination of several frames is called a packet.
mSampleRateThat is, the frequency of use
mBitsPerChannelThat is, the number of digits of each sampled data
mChannelsPerFrameIt can be understood as the number of channels, that is, several sampling data are generated at a sampling time.
mFramesPerPacketThe number of frames in each packet is equal to the number of sampling intervals in this packet.
mBytesPerPacketThe number of bytes of data in each packet.
mBytesPerFrame, The number of bytes of data in each frame

Calculation Formula

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

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.