TCRAudioFrame Class Reference

Inherits from NSObject
Declared in AudioSink.h
AudioSink.m

Overview

通常播放时我们设置的参数为 audioDescription.mSampleRate = 48000; audioDescription.mFormatID = kAudioFormatLinearPCM; audioDescription.mFormatFlags = kLinearPCMFormatFlagIsSignedInteger | kAudioFormatFlagIsPacked; audioDescription.mChannelsPerFrame = 2; audioDescription.mFramesPerPacket = 1; audioDescription.mBitsPerChannel = 16; audioDescription.mBytesPerFrame = 4; audioDescription.mBytesPerPacket = audioDescription.mBytesPerFrame * audioDescription.mFramesPerPacket;

  data

音频数据

@property (nonatomic, copy) NSData *data

Discussion

音频数据

Declared In

AudioSink.h

  bitsPerSample

每个音频样本的位数

@property (nonatomic, assign) int bitsPerSample

Discussion

每个音频样本的位数

Declared In

AudioSink.h

  sampleRate

音频的采样率

@property (nonatomic, assign) int sampleRate

Discussion

音频的采样率

Declared In

AudioSink.h

  channels

音频数据中的通道数量

@property (nonatomic, assign) int channels

Discussion

音频数据中的通道数量

Declared In

AudioSink.h

  frames

音频数据中的样本帧数

@property (nonatomic, assign) int frames

Discussion

音频数据中的样本帧数

Declared In

AudioSink.h