-
- All Implemented Interfaces:
public interface VdoPlayer.PlaybackEventListener
Interface for callbacks related to playback events.
-
-
Method Summary
Modifier and Type Method Description abstract void
onPlayerStateChanged(boolean playWhenReady, int playbackState)
Called when the value returned from either getPlayWhenReady or getPlaybackState changes. abstract void
onSeekTo(long millis)
Called when seeking completes. abstract void
onProgress(long millis)
Video playback progress callback abstract void
onBufferUpdate(long bufferTime)
Video buffer update callback abstract void
onPlaybackSpeedChanged(float speed)
Called when the current playback speed changes. abstract void
onLoading(VdoInitParams vdoInitParams)
Called when the player starts loading a media. abstract void
onLoaded(VdoInitParams vdoInitParams)
Called when a requested media is currently loaded by the player abstract void
onLoadError(VdoInitParams vdoParams, ErrorDescription errorDescription)
Called when a media could not be loaded. abstract void
onMediaEnded(VdoInitParams vdoInitParams)
Called when the player has completed playing a media. abstract void
onError(VdoInitParams vdoParams, ErrorDescription errorDescription)
Called when an error is encountered during playback and playback cannot proceed abstract void
onTracksChanged(Array<Track> availableTracks, Array<Track> selectedTracks)
Called when the available or selected tracks change -
-
Method Detail
-
onPlayerStateChanged
abstract void onPlayerStateChanged(boolean playWhenReady, int playbackState)
Called when the value returned from either getPlayWhenReady or getPlaybackState changes.
- Parameters:
playWhenReady
- whether playback will proceed when readyplaybackState
- current state of player (one of theSTATE
constants defined in VdoPlayer
-
onSeekTo
abstract void onSeekTo(long millis)
Called when seeking completes.
- Parameters:
millis
- current time in milliseconds after seeking has completed
-
onProgress
abstract void onProgress(long millis)
Video playback progress callback
- Parameters:
millis
- current time in milliseconds
-
onBufferUpdate
abstract void onBufferUpdate(long bufferTime)
Video buffer update callback
- Parameters:
bufferTime
- time in milliseconds till which the video is buffered
-
onPlaybackSpeedChanged
abstract void onPlaybackSpeedChanged(float speed)
Called when the current playback speed changes.
- Parameters:
speed
- the currently active playback speed
-
onLoading
abstract void onLoading(VdoInitParams vdoInitParams)
Called when the player starts loading a media.
- Parameters:
vdoInitParams
- VdoInitParams which the player is currently loading
-
onLoaded
abstract void onLoaded(VdoInitParams vdoInitParams)
Called when a requested media is currently loaded by the player
- Parameters:
vdoInitParams
- params which the player has loaded
-
onLoadError
abstract void onLoadError(VdoInitParams vdoParams, ErrorDescription errorDescription)
Called when a media could not be loaded.
- Parameters:
vdoParams
- the VdoInitParams passed to load for which load failederrorDescription
- ErrorDescription object describing the error
-
onMediaEnded
abstract void onMediaEnded(VdoInitParams vdoInitParams)
Called when the player has completed playing a media.
- Parameters:
vdoInitParams
- the VdoInitParams for which playback has completed
-
onError
abstract void onError(VdoInitParams vdoParams, ErrorDescription errorDescription)
Called when an error is encountered during playback and playback cannot proceed
- Parameters:
vdoParams
- the VdoInitParams passed to load for which error occurrederrorDescription
- ErrorDescription object describing the error
-
onTracksChanged
abstract void onTracksChanged(Array<Track> availableTracks, Array<Track> selectedTracks)
Called when the available or selected tracks change
- Parameters:
availableTracks
- array containing the currently available tracksselectedTracks
- array containing the currently selected tracks
-
-
-
-