MediaPeriod.Callback


interface MediaPeriod.Callback : SequenceableLoader.Callback

Known direct subclasses
ClippingMediaPeriod

Wraps a MediaPeriod and clips its SampleStreams to provide a subsequence of their samples.

MaskingMediaPeriod

Media period that defers calling createPeriod on a given source until createPeriod has been called.


A callback to be notified of MediaPeriod events.

Summary

Public functions

Unit
onPrepared(mediaPeriod: MediaPeriod!)

Called when preparation completes.

Inherited functions

From androidx.media3.exoplayer.source.SequenceableLoader.Callback
Unit

Called by the loader to indicate that it wishes for its continueLoading method to be called when it can continue to load data.

Public functions

onPrepared

fun onPrepared(mediaPeriod: MediaPeriod!): Unit

Called when preparation completes.

Called on the playback thread. After invoking this method, the MediaPeriod can expect for selectTracks to be called with the initial track selection.

Parameters
mediaPeriod: MediaPeriod!

The prepared MediaPeriod.