|
TuyaOS
|
audio frame 更多...
#include <tkl_cellular_player.h>
成员变量 | |
| UINT_T | bytes |
| UINT8_T | channelCount |
| PUINT_T | data |
| UINT8_T | flags |
| TKL_AUDIO_SAMPLE_FORMAT_T | sampleFormat |
| UINT_T | sampleRate |
| UINT_T | sampleStamp |
audio frame
When it is used for format only, only sampleFormat, channelCount and sampleRate are used.
| UINT_T TKL_AUDIO_FRAME_T::bytes |
byte count (not sample count)
| UINT8_T TKL_AUDIO_FRAME_T::channelCount |
channel count, only 1 and 2 are valid now
| PUINT_T TKL_AUDIO_FRAME_T::data |
sample pointer, it can be casted to the data type according to sampleFormat. For 2 channels, the format is LRLR...
| TKL_AUDIO_SAMPLE_FORMAT_T TKL_AUDIO_FRAME_T::sampleFormat |
sample format
| UINT_T TKL_AUDIO_FRAME_T::sampleRate |
sample rate in Hz
| UINT_T TKL_AUDIO_FRAME_T::sampleStamp |
time stamp of the beginning of data, in unit of sample count. time_stamp = sample_stamp/sample_rate