PlayerEvent
sealed class PlayerEvent : Event
Includes all possible events that only the Player can emit.
Inheritors
| AdBreakStarted |
| AdBreakFinished |
| AdError |
| AdStarted |
| AdClicked |
| AdFinished |
| AdLinearityChanged |
| AdManifestLoad |
| AdManifestLoaded |
| AdQuartile |
| AdScheduled |
| AdScheduleChanged |
| AdSkipped |
| AudioPlaybackQualityChanged |
| CastAvailable |
| CastPaused |
| CastPlaybackFinished |
| CastPlaying |
| CastStarted |
| CastStart |
| CastStopped |
| CastTimeUpdated |
| CastWaitingForDevice |
| CueEnter |
| CueExit |
| DownloadFinished |
| Destroy |
| DroppedVideoFrames |
| DvrWindowExceeded |
| Error |
| Warning |
| Info |
| FullscreenEnabled |
| FullscreenDisabled |
| FullscreenEnter |
| FullscreenExit |
| Impression |
| LicenseValidated |
| Metadata |
| Muted |
| PictureInPictureAvailabilityChanged |
| PictureInPictureEnter |
| PictureInPictureEntered |
| PictureInPictureExit |
| PictureInPictureExited |
| PlaybackFinished |
| Active |
| Inactive |
| SourceAdded |
| SourceRemoved |
| Play |
| Playing |
| Paused |
| PlaylistTransition |
| Ready |
| RenderFirstFrame |
| FrameAboutToBeRendered |
| Seek |
| Seeked |
| StallEnded |
| StallStarted |
| TimeChanged |
| TimeShift |
| TimeShifted |
| Unmuted |
| VideoPlaybackQualityChanged |
| VideoSizeChanged |
| VrStereoChanged |
| VrViewingDirectionChanged |
| VrViewingDirectionChange |
| ScalingModeChanged |
Types
| Name | Summary |
|---|---|
| Active | class Active : PlayerEvent Emitted when a playback session was started. This event is emitted immediately after the load call und does not wait for actual data to be loaded. |
| AdBreakFinished | data class AdBreakFinished(val adBreak: AdBreak? = null) : PlayerEvent Emitted when an ad break has finished. |
| AdBreakStarted | data class AdBreakStarted(val adBreak: AdBreak? = null) : PlayerEvent Emitted when an ad break has started. |
| AdClicked | data class AdClicked(val clickThroughUrl: String?) : PlayerEvent Emitted when an ad was clicked. |
| AdError | data class AdError(val adItem: AdItem?, val code: Int, val message: String?, val adConfig: AdConfig? = null) : PlayerEvent Emitted when an error with the ad playback occurs. |
| AdFinished | data class AdFinished(val ad: Ad? = null) : PlayerEvent Emitted when an ad has finished playback. |
| AdLinearityChanged | data class AdLinearityChanged(val isLinear: Boolean) : PlayerEvent Emitted when the linearity of a VPAID ad changes. |
| AdManifestLoad | data class AdManifestLoad(val adConfig: AdConfig, val adBreak: AdBreak? = null) : PlayerEvent Emitted when the download of an ad manifest is started. |
| AdManifestLoaded | data class AdManifestLoaded(val adConfig: AdConfig, val adBreak: AdBreak? = null, val downloadTime: Long) : PlayerEvent Emitted when an ad manifest was successfully loaded. |
| AdQuartile | data class AdQuartile(val quartile: AdQuartile) : PlayerEvent Emitted when the playback of an ad has progressed over a quartile boundary. |
| AdScheduleChanged | data class AdScheduleChanged(val oldSchedule: List<AdBreak>, val newSchedule: List<AdBreak>) : PlayerEvent Emitted when the AdvertisingApi.schedule changes. |
| AdScheduled | data class AdScheduled(val numberOfAds: Int) : PlayerEvent Emitted when an ad was successfully scheduled into the player. |
| AdSkipped | data class AdSkipped(val ad: Ad? = null) : PlayerEvent Emitted when an ad was skipped. |
| AdStarted | data class AdStarted(val clientType: AdSourceType?, val clickThroughUrl: String?, val indexInQueue: Int, val duration: Double, val timeOffset: Double, val position: String?, val skipOffset: Double, val ad: Ad? = null) : PlayerEvent Emitted when the playback of an ad has started. |
| AudioPlaybackQualityChanged | data class AudioPlaybackQualityChanged(val oldAudioQuality: AudioQuality?, val newAudioQuality: AudioQuality?) : PlayerEvent Emitted when the current audio playback quality has changed. |
| CastAvailable | class CastAvailable : PlayerEvent Emitted when casting to a cast-compatible device is available. |
| CastPaused | class Emitted when the playback on a cast-compatible device was paused. |
| CastPlaybackFinished | class Emitted when the playback on a cast-compatible device has finished. |
| CastPlaying | class Emitted when playback on a cast-compatible device has started. |
| CastStart | class CastStart : PlayerEvent Emitted when casting is initiated, but the user still needs to choose which device should be used. |
| CastStarted | data class CastStarted(val deviceName: String?) : PlayerEvent Emitted when the cast app is launched successfully. |
| CastStopped | class CastStopped : PlayerEvent Emitted when casting to a cast-compatible device is stopped. |
| CastTimeUpdated | class CastTimeUpdated : PlayerEvent Emitted when the time update from the currently used cast-compatible device is received. |
| CastWaitingForDevice | data class CastWaitingForDevice(val castPayload: CastPayload) : PlayerEvent Emitted when a cast-compatible device has been chosen and the player is waiting for the device to get ready for playback. |
| CueEnter | data class CueEnter(val cue: Cue) : PlayerEvent Emitted when a subtitle cue transitions into the active status. |
| CueExit | data class CueExit(var cue: Cue) : PlayerEvent Emitted when an active subtitle cue transitions into the inactive status. |
| Destroy | class Destroy : PlayerEvent Emitted when the player was destroyed. |
| DownloadFinished | data class DownloadFinished(val downloadType: HttpRequestType, val url: String, val lastRedirectLocation: String?, val downloadTime: Double, val httpStatus: Int, val size: Long, val isSuccess: Boolean) : PlayerEvent Emitted when a download was finished that is not directly related to a specific source. |
| DroppedVideoFrames | data class DroppedVideoFrames(val droppedFrames: Int, val elapsedTime: Double) : PlayerEvent Emitted when video frames have been dropped. |
| DvrWindowExceeded | class DvrWindowExceeded : PlayerEvent Emitted when the player is paused or in buffering state and the timeShift offset has exceeded the available timeShift window. |
| Error | data class Error(val code: PlayerErrorCode, val message: String, val data: Any? = null, val deficiencyData: DeficiencyData? = null) : ErrorEvent, PlayerEvent Emitted when a player error occurred. |
| FrameAboutToBeRendered | data class FrameAboutToBeRendered(val presentationTimeUs: Long, val releaseTimeNs: Long) : PlayerEvent Emitted for every frame that will be rendered onto the video surface. This event needs to be enabled by setting Player.isFrameAboutToBeRenderedEventEnabled to true. The event will be emitted on the playback thread. It is very important that handling this event must be done very efficient to not block the playback thread. |
| FullscreenDisabled | class FullscreenDisabled : PlayerEvent Emitted when the fullscreen functionality has been disabled. |
| FullscreenEnabled | class FullscreenEnabled : PlayerEvent Emitted when the fullscreen functionality has been enabled. |
| FullscreenEnter | class FullscreenEnter : PlayerEvent Emitted when the player enters fullscreen mode. |
| FullscreenExit | class FullscreenExit : PlayerEvent Emitted when the player exits fullscreen mode. |
| Impression | data class Impression(val data: ImpressionData) : PlayerEvent Emitted when an impression call succeeded. |
| Inactive | class Inactive : PlayerEvent Emitted when the active playback session was stopped. |
| Info | data class Info(val message: String) : InfoEvent, PlayerEvent Emitted for neutral information provided by the player. The information provided with this event is only for analytical purposes and are subject to change. Thus, neither the timing nor the content should be used to trigger workflows, but may be used for logging. |
| LicenseValidated | data class LicenseValidated(val data: LicenseData) : PlayerEvent Emitted when a licensing call succeeded. |
| Metadata | data class Metadata(val metadata: Metadata, val type: String) : PlayerEvent Emitted when metadata (e.g. Id3Frame in HLS and EventMessage in DASH) is encountered. |
| Muted | class Muted : PlayerEvent Emitted when the player is muted on either the local device or on a cast-compatible device. |
| Paused | data class Paused(val time: Double) : PlayerEvent Emitted when the player is paused. |
| PictureInPictureAvailabilityChanged | data class PictureInPictureAvailabilityChanged(val isPictureInPictureAvailable: Boolean) : PlayerEvent Emitted when the availability of the Picture-in-Picture mode changed. |
| PictureInPictureEnter | class PictureInPictureEnter : PlayerEvent Emitted when the player enters Picture-In-Picture mode. |
| PictureInPictureEntered | class PictureInPictureEntered : PlayerEvent Emitted when the enter transition of the player to Picture-In-Picture mode is completed. |
| PictureInPictureExit | class PictureInPictureExit : PlayerEvent Emitted when the player exits Picture-In-Picture mode. |
| PictureInPictureExited | class PictureInPictureExited : PlayerEvent Emitted when the exit transition of the player from Picture-In-Picture mode is completed. |
| Play | data class Play(val time: Double) : PlayerEvent Emitted when the player receives an intention to play (i.e Player.play). |
| PlaybackFinished | class PlaybackFinished : PlayerEvent Emitted when playback of the Source has finished. If multiple sources are loaded into the player via a PlaylistConfig, the event is emitted when playback of the last Source in the playlist finished. |
| Playing | data class Playing(val time: Double) : PlayerEvent Emitted when the player enters the playing state after calling Player.play. |
| PlaylistTransition | data class PlaylistTransition(val from: Source, val to: Source) : PlayerEvent Emitted when the player transitions between two sources in a playlist. |
| Ready | class Ready : PlayerEvent Emitted when the player is ready to play and to handle API calls. |
| RenderFirstFrame | class RenderFirstFrame : PlayerEvent Emitted when the first frame of the current video is rendered onto the video surface. |
| ScalingModeChanged | data class ScalingModeChanged(val from: ScalingMode, val to: ScalingMode) : PlayerEvent Emitted when the PlayerView.getScalingMode is changed. |
| Seek | data class Seek(val from: SeekPosition, val to: SeekPosition) : PlayerEvent Emitted when the player starts seeking. Only applies to VoD streams. Refer to TimeShift for live streams. |
| Seeked | class Seeked : PlayerEvent Emitted when seeking has finished and data is available to continue playback. Only applies to VoD streams. Refer to TimeShifted for live streams. |
| SourceAdded | data class SourceAdded(val source: Source, val index: Int) : PlayerEvent Emitted when a Source was added to an active playback session. |
| SourceRemoved | data class SourceRemoved(val source: Source, val index: Int) : PlayerEvent Emitted when a Source was removed from an active playback session. |
| StallEnded | class StallEnded : PlayerEvent Emitted when the player ends stalling due to enough data being buffered. |
| StallStarted | class StallStarted : PlayerEvent Emitted when the player begins to stall and to buffer due to an empty buffer. |
| TimeChanged | data class TimeChanged(val time: Double) : PlayerEvent Emitted when the current playback time has changed. |
| TimeShift | data class TimeShift(val position: Double, val target: Double) : PlayerEvent Emitted when the player starts time shifting. Only applies to live streams. Refer to Seek for VoD streams. |
| TimeShifted | class TimeShifted : PlayerEvent Emitted when time shifting has finished and data is available to continue playback. Only applies to live streams. Refer to Seeked for VoD streams. |
| Unmuted | class Unmuted : PlayerEvent Emitted when the player is unmuted on either the local device or on a cast-compatible device. |
| VideoPlaybackQualityChanged | data class VideoPlaybackQualityChanged(val oldVideoQuality: VideoQuality?, val newVideoQuality: VideoQuality?) : PlayerEvent Emitted when the current video playback quality has changed. |
| VideoSizeChanged | data class VideoSizeChanged(val width: Int, val height: Int, val aspectRatio: Float) : PlayerEvent Emitted when the current size of the video content has changed. |
| VrStereoChanged | data class VrStereoChanged(val isStereo: Boolean) : PlayerEvent Emitted when the VR stereo mode during playback of VR content changes. |
| VrViewingDirectionChange | class VrViewingDirectionChange : PlayerEvent Emitted when the VR viewing direction changes. The minimal interval between two consecutive event callbacks is specified through VrConfig.viewingDirectionChangeEventInterval. |
| VrViewingDirectionChanged | class VrViewingDirectionChanged : PlayerEvent Emitted when the VR viewing direction did not change more than the specified threshold in the last interval, after the VrViewingDirectionChange event was triggered. The threshold can be set through setVRViewingDirectionChangeThreshold. |
| Warning | data class Warning(val code: PlayerWarningCode, val message: String, val deficiencyData: DeficiencyData? = null) : WarningEvent, PlayerEvent Emitted when a player warning occurred. |