media/library
tonihei 91c2f891a0 Ensure BandwidthProfileDataSource loading is fully deterministic
We currently block the loading thread until the calculated load
time has past and then unblock again by a message sent from the
playback thread. However, because the loading thread itself is not
using a Looper and runs freely, we don't control when the short
calculations on the loader thread that determine how long we have
to wait are happening, and we also don't control how long it takes
to start and stop this thread.

To solve these problems and to make the playback deterministic we
can
 1. Send a message on the playback thread to block until the loader
    thread has started.
 2. Block the playback thread whenever a loading thread is doing its
    short calculation of wait times. The playback thread knows when it
    can continue because loading either enter a new waiting state for
    a simulated load time or loading is finished completely.
 3. Also wait on the playback thread until the loader has shut down.
    As this is waiting for a message on the playback thread, we can
    achieve this by sending messages to ourselves at the current time
    until the loader is shut down.
All 3 steps together ensure that the loading thread interaction is
compeltely deterministic when simulating bandwidth profiles with the
BandwidthProfileDataSource. As we need to notify the source before and
after the load started/finished, we also need a small wrapper for the
chunk source when running the playback.

PiperOrigin-RevId: 355810408
2021-02-09 13:58:42 +00:00
..
all Add Transformer "Getting started" page 2021-02-03 15:03:16 +00:00
common Ensure BandwidthProfileDataSource loading is fully deterministic 2021-02-09 13:58:42 +00:00
core Consistently throw the original exception if recovery fails 2021-02-09 13:58:33 +00:00
dash Replace non-inclusively named constant 2021-01-25 17:38:26 +00:00
extractor Fix parsing of Vorbis codec private 2021-01-26 15:59:41 +00:00
hls Suppress SwitchIntDef warning where it makes sense 2021-02-04 00:24:04 +00:00
smoothstreaming Split mutations method out of TrackSelection 2021-01-25 15:37:38 +00:00
transformer Avoid skipping the first decoder output buffers after speed change 2021-02-04 18:14:35 +00:00
ui Add PlayerNotificationManager.Builder 2021-02-03 15:02:59 +00:00
README.md Tweak and add READMEs + remove refs to V1 2017-08-17 22:59:34 +01:00

ExoPlayer library

The ExoPlayer library is split into multiple modules. See ExoPlayer's top level README for more information about the available library modules and how to use them.