ExoTrackSelection.Factory


public interface ExoTrackSelection.Factory


Factory for ExoTrackSelection instances.

Summary

Public methods

abstract ExoTrackSelection[]
@NullableType
createTrackSelections(
    @NullableType ExoTrackSelection.Definition[] definitions,
    BandwidthMeter bandwidthMeter,
    MediaSource.MediaPeriodId mediaPeriodId,
    Timeline timeline
)

Creates track selections for the provided Definitions.

Public methods

createTrackSelections

@NullableType
abstract ExoTrackSelection[] createTrackSelections(
    @NullableType ExoTrackSelection.Definition[] definitions,
    BandwidthMeter bandwidthMeter,
    MediaSource.MediaPeriodId mediaPeriodId,
    Timeline timeline
)

Creates track selections for the provided Definitions.

Implementations that create at most one adaptive track selection may use createTrackSelectionsForDefinitions.

Parameters
@NullableType ExoTrackSelection.Definition[] definitions

A Definition array. May include null values.

BandwidthMeter bandwidthMeter

A BandwidthMeter which can be used to select tracks.

MediaSource.MediaPeriodId mediaPeriodId

The MediaPeriodId of the period for which tracks are to be selected.

Timeline timeline

The Timeline holding the period for which tracks are to be selected.

Returns
ExoTrackSelection[]

The created selections. Must have the same length as definitions and may include null values.