mirror of
https://github.com/samsonjs/media.git
synced 2026-04-04 11:05:47 +00:00
Init the ads manager for placeholder timelines
It looks like loading ad cue points would cause a source info refresh causing the content media period load to be canceled, meaning we would never get a non-placeholder timeline. This changes ensures that the ads manager will still be initialized, avoiding playback getting stuck when playing a ProgressiveMediaPeriod with a preroll ad. PiperOrigin-RevId: 298814758
This commit is contained in:
parent
d8ea1f60af
commit
470ec9e5d1
1 changed files with 0 additions and 4 deletions
|
|
@ -967,10 +967,6 @@ public final class ImaAdsLoader
|
|||
return;
|
||||
}
|
||||
Assertions.checkArgument(timeline.getPeriodCount() == 1);
|
||||
if (timeline.getWindow(/* windowIndex= */ 0, window).isPlaceholder) {
|
||||
// This is just a placeholder. Wait until we get the fully prepared timeline.
|
||||
return;
|
||||
}
|
||||
this.timeline = timeline;
|
||||
long contentDurationUs = timeline.getPeriod(/* periodIndex= */ 0, period).durationUs;
|
||||
contentDurationMs = C.usToMs(contentDurationUs);
|
||||
|
|
|
|||
Loading…
Reference in a new issue