hi_aenc_chn_attr
Description
Defines the attributes of an audio encoding channel.
Definition
typedef struct {
hi_payload_type type;
hi_u32 point_num_per_frame;
hi_u32 buf_size;
hi_void ATTRIBUTE *value;
} hi_aenc_chn_attr;
Members
Member |
Description |
|---|---|
type |
Audio encoding protocol type. Currently, HI_PT_G711A, HI_PT_G711U, and HI_PT_AAC are supported. This is a static attribute. |
point_num_per_frame |
Required frame length for the audio encoding protocol (if the received audio frame length is less than or equal to the required frame length, the received frame can be encoded.) For G.711a and G.711u encoding, the frame length can be 80, 160, 240, 320, or 480. For AAC encoding, the frame length can only be 1024. |
buf_size |
Size of the audio encoding buffer, in frames. For G.711a and G.711u encoding, the value range of this parameter is [2, 100]. For AAC encoding, the value range is [10, 80]. This is a static attribute. |
value |
Pointer to the specific protocol attribute. For G.711a and G.711u encoding, the value of this parameter is invalid and can be any non-null pointer. For AAC encoding, the hi_aenc_attr_aac structure variable must be passed. This is a static attribute. |