Agora Server Gateway SDK Java API Reference
Loading...
Searching...
No Matches
io.agora.rtc.AgoraMediaPacketSender Class Reference

Public Member Functions

 AgoraMediaPacketSender (long cptr)
 
native int send (byte[] packet, int length, PacketOptions options)
 
void destroy ()
 

Private Member Functions

native void ndestroy ()
 

Private Attributes

long cptr
 

Detailed Description

The AgoraMediaPacketSender class.

You can use the AgoraMediaPacketSender class to create a LocalVideoTrack or LocalAudioTrack, and then send media packets directly to the track. The media packets are RTP/UDP packets that contain media payload. If the track is disabled, the packets will be automatically discarded.

Constructor & Destructor Documentation

◆ AgoraMediaPacketSender()

io.agora.rtc.AgoraMediaPacketSender.AgoraMediaPacketSender ( long cptr)

Constructor.

Member Function Documentation

◆ destroy()

void io.agora.rtc.AgoraMediaPacketSender.destroy ( )

Destructor.

◆ ndestroy()

native void io.agora.rtc.AgoraMediaPacketSender.ndestroy ( )
private

◆ send()

native int io.agora.rtc.AgoraMediaPacketSender.send ( byte[] packet,
int length,
PacketOptions options )

Sends the frame packet to the local track.

Parameters
packetThe pointer to the packet.
lengthThe packet size.
optionsThe packet information.
Returns
  • true: Success.
  • false: Failure.

Member Data Documentation

◆ cptr

long io.agora.rtc.AgoraMediaPacketSender.cptr
private

The documentation for this class was generated from the following file: