Agora RTC Objective-C API Reference Refactor

Public Member Functions
IAudioEncodedFrameSender Class Referenceabstract

Inherits RefCountInterface.

## Public Member Functions
virtual bool | sendEncodedAudioFrame (const uint8_t *payload_data, size_t payload_size, const EncodedAudioFrameInfo &audioFrameInfo)=0

## Detailed Description

The `IAudioEncodedFrameSender` class.

In scenarios involving custom audio source, you can use the `IAudioEncodedFrameSender` class to send encoded audio data directly to the audio track. If the track is disabled, the sent audio data will be automatically discarded.

## Constructor & Destructor Documentation

## ◆ ~IAudioEncodedFrameSender()

~IAudioEncodedFrameSender | ( |  | ) |
| inlineprotected

## Member Function Documentation

## ◆ sendEncodedAudioFrame()

virtual bool sendEncodedAudioFrame | ( | const uint8_t * | payload_data,
|  | size_t | payload_size,
|  | const EncodedAudioFrameInfo & | audioFrameInfo
| ) |  |
| pure virtual

Sends the encoded audio frame to the local audio track.

Parameters

  payload_data | The pointer to the payload data.
  payload_size | The payload size.
  audioFrameInfo | The reference to the information of the audio frame: EncodedAudioFrameInfo.

Returns
  - `true`: Success.
  - `false`: Failure.

## ◆ AddRef()

virtual void AddRef | ( |  | ) | const
| pure virtualinherited

## ◆ Release()

virtual RefCountReleaseStatus Release | ( |  | ) | const
| pure virtualinherited

## ◆ HasOneRef()

virtual bool HasOneRef | ( |  | ) | const
| pure virtualinherited