Agora C++ API Reference for All Platforms

Loading...
Searching...
No Matches
Public Member Functions | List of all members
agora::rtc::IMediaPacketReceiver Class Referenceabstract

`#include <NGIAgoraMediaNode.h>`

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

## 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 agora::rtc::IMediaPacketReceiver::~IMediaPacketReceiver | ( |  | ) |
| inline virtual

## Member Function Documentation

## ◆ onMediaPacketReceived()

virtual bool agora::rtc::IMediaPacketReceiver::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.