Package-level declarations

Types

Link copied to clipboard

Default configuration for creating a PillarboxExoPlayer, which closely matches an ExoPlayer.

Link copied to clipboard
abstract class PillarboxBuilder

A builder class for creating instances of PillarboxExoPlayer.

Link copied to clipboard
annotation class PillarboxDsl

Marks a class or function as part of the Pillarbox DSL (Domain Specific Language).

Link copied to clipboard
Link copied to clipboard
class PillarboxLoadControl(bufferDurations: PillarboxLoadControl.BufferDurations = DEFAULT_BUFFER_DURATIONS, allocator: DefaultAllocator = DefaultAllocator(true, C.DEFAULT_BUFFER_SEGMENT_SIZE)) : LoadControl

A LoadControl implementation tailored for Pillarbox, optimizing content loading.

Link copied to clipboard

Pillarbox Player interface extension.

Link copied to clipboard
class PillarboxPreloadManager(context: Context, targetPreloadStatusControl: TargetPreloadStatusControl<Int>? = null, mediaSourceFactory: PillarboxMediaSourceFactory = PillarboxMediaSourceFactory(context), trackSelector: TrackSelector = PillarboxTrackSelector(context), bandwidthMeter: BandwidthMeter = PillarboxBandwidthMeter(context), renderersFactory: RenderersFactory = PillarboxRenderersFactory(context), loadControl: LoadControl = PillarboxLoadControl(), playbackThread: HandlerThread = HandlerThread("PillarboxPreloadManager:Playback", Process.THREAD_PRIORITY_AUDIO))

Helper class for Media3's DefaultPreloadManager that simplifies preloading of media items for PillarboxExoPlayer.

Link copied to clipboard

Defines a factory for creating instances of PillarboxBuilder.

Properties

Link copied to clipboard

The default interval between Flow emissions.

Functions

Link copied to clipboard
fun Player.currentBufferedPercentageAsFlow(updateInterval: Duration = DefaultUpdateInterval): Flow<Float>

Collects the buffered percentage as a Flow.

Link copied to clipboard
Link copied to clipboard
fun Player.currentMediaMetadataAsFlow(withPlaylistMediaMetadata: Boolean = false): Flow<MediaMetadata>

Collects the media metadata as a Flow.

Link copied to clipboard
fun Player.currentPositionAsFlow(updateInterval: Duration = DefaultUpdateInterval): Flow<Long>

Collects the current position of the player as a Flow.

Link copied to clipboard

Collects the duration as a Flow.

Link copied to clipboard
fun Player.getAspectRatioAsFlow(defaultAspectRatio: Float): Flow<Float>

Collects the aspect ratio of the current video as a Flow.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Collects the timeline's default position, in milliseconds, as a Flow.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Collects whether the current media item is a live stream as a Flow.

Link copied to clipboard
fun Player.isPlaybackSpeedPossibleAtPosition(position: Long, speed: Float, window: Timeline.Window = Window()): Boolean

Return if the playback speed is possible at position. Always return true for none live content or if Player.getCurrentTimeline is empty.

Link copied to clipboard

Collects whether the player is playing as a Flow.

Link copied to clipboard
Link copied to clipboard

Provides a pre-configured instance of BandwidthMeter suitable for use within Pillarbox.

Link copied to clipboard

Create a new instance of PillarboxExoPlayer.

Link copied to clipboard

Provides a pre-configured instance of RenderersFactory suitable for use within Pillarbox.

Link copied to clipboard

Provides a pre-configured instance of TrackSelector suitable for use within Pillarbox.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Creates a PreloadConfiguration instance using a Duration.

Link copied to clipboard

Run the task in the same thread as Player.getApplicationLooper if it is necessary.

Link copied to clipboard
Link copied to clipboard
fun Player.tickerWhilePlayingAsFlow(interval: Duration = DefaultUpdateInterval): Flow<Unit>

Emits an event every interval while the Player is playing.

Link copied to clipboard