Main methods

Method Description
AgoraMediaPlayerKit Creates an AgoraMediaPlayerKit instance.
destroy Destroys an AgoraMediaPlayerKit instance.
registerPlayerObserver Registers a player observer.
unregisterPlayerOberver Unregisters a player observer.
registerAudioFrameObserver Registers an audio observer.
unregisterAudioFrameObserver Unregisters an audio observer.
registerVideoFrameObserver Registers a video observer.
unregisterVideoFrameObserver Unregisters a video observer.
setView Sets the player's render view.
setRenderMode Sets the player's render mode.
open Open the media resource.
play Plays the media resource.
pause Pauses the playback.
stop Stops the playback.
seek Seeks to a new playback position.
adjustPlayoutVolume Adjusts the local playback volume.
mute Sets whether to mute the media resource.
getDuration Gets the duration of the media resource.
getPlayPosition Gets current playback progress.
getPlayoutVolume Gets current local playback volume.
isMuted Confirms whether the media resource is muted.
getState Gets current playback state.
getStreamCount Gets the number of the media streams in the media resource.
getStreamInfo Gets the detailed information of the media stream.

Main events

Event Description
onPlayerStateChanged Reports the playback state change.
onPositionChanged Reports current playback progress.
onPlayerEvent Reports the result of the seek operation.
onMetaData Reports the reception of the media metadata.
onFrame Occurs when each time the player receives an audio frame.
onFrame Occurs when each time the player receives a video frame.