Agora RTC Objective-C API Reference Refactor

Public Member Functions
IMediaPacketReceiver Class Referenceabstract

## Public Member Functions
virtual bool | onMediaPacketReceived (const uint8_t *packet, size_t length, const agora::media::base::PacketOptions &options)=0

## Detailed Description

The IMediaPacketReceiver class. You can register a receiver in remote audio or video tracks to trigger callbacks when RTP/UDP packets are received.

## Constructor & Destructor Documentation

## ◆ ~IMediaPacketReceiver()

virtual ~IMediaPacketReceiver | ( |  | ) |
| inline virtual

## Member Function Documentation

## ◆ onMediaPacketReceived()

virtual bool onMediaPacketReceived | ( | const uint8_t * | packet,
|  | size_t | length,
|  | const agora::media::base::PacketOptions & | options
| ) |  |
| pure virtual

Occurs when the track receives a media packet.

Parameters

  packet | The pointer to the media packet.
  length | The length of the packet.
  options | The packet info.