mirror of
https://github.com/androidx/media.git
synced 2025-04-30 06:46:50 +08:00

This adds the option to disable certain track types during scrubbing, with audio and metadata disabled by default. The tracks are disabled by modifying the `TrackSelectionParameters`, but in a way that is invisible to `Player.getTrackSelectionParameters()` and `Player.Listener.onTrackSelectionParametersChanged`. This allows us to clearly reason about what should happen if `Player.setTrackSelectionParameters(...)` is called during scrubbing mode. The **side effects** of disabling the tracks are all visible through `Player.Listener` and `AnalyticsListener` (renderer disabled, decoder released, `onTracksChanged`, etc.). PiperOrigin-RevId: 743961632