Fix seeking in the last period.
When reading the last period, the readingPeriodHolder was set to null in updatePeriods if it was the last period. (This would occur almost immediately when playing a single-period source.) seekToPeriodPosition suppresses reusing a loaded/prepared period if the reading period and playing period did not match, which meant that the whole timeline was recreated when seeking in the last period. Leave readingPeriodHolder non-null. This means that at all times either playingPeriodHolder == readingPeriodHolder (and they could be null or non-null), or playingPeriodHolder and readingPeriodHolder differ and are both non-null. Also fix an issue where streams were never forced to be recreated during track reselection when reading ahead. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=134774238
Showing
with
12 additions
and
17 deletions
Please
register
or
sign in
to comment